]> git.openstreetmap.org Git - rails.git/commitdiff
Fixed bad coding practice in test.
authorMatt Amos <zerebubuth@gmail.com>
Thu, 30 Apr 2009 18:12:23 +0000 (18:12 +0000)
committerMatt Amos <zerebubuth@gmail.com>
Thu, 30 Apr 2009 18:12:23 +0000 (18:12 +0000)
test/unit/relation_tag_test.rb

index 02800d360231ef1ec48071a5ce662598f0a94926..e091efb0f27e36ba5857beceb1d1bbcc33fd6e18 100644 (file)
@@ -78,7 +78,8 @@ class RelationTagTest < Test::Unit::TestCase
     assert_equal 0, RelationTag.count(:conditions => ['v=?', v])
 
     # make sure we select a tag on a relation which has more than one tag
-    tag = RelationTag.find(:first, :conditions => ["id = ?", 4])
+    id = current_relations(:multi_tag_relation).id
+    tag = RelationTag.find(:first, :conditions => ["id = ?", id])
     tag.v = v
     tag.save!