]> git.openstreetmap.org Git - rails.git/blobdiff - test/models/relation_test.rb
Merge branch 'master' into moderation
[rails.git] / test / models / relation_test.rb
index cb0d54a9b99c0bb1bfa66d0bcdfdd62401fecab3..b06cbd9b85843be99ab930df7048f58092c989f8 100644 (file)
@@ -1,15 +1,9 @@
 require "test_helper"
 
 class RelationTest < ActiveSupport::TestCase
-  api_fixtures
-
-  def test_relation_count
-    assert_equal 8, Relation.count
-  end
-
   def test_from_xml_no_id
     noid = "<osm><relation version='12' changeset='23' /></osm>"
-    assert_nothing_raised(OSM::APIBadXMLError) do
+    assert_nothing_raised do
       Relation.from_xml(noid, true)
     end
     message = assert_raise(OSM::APIBadXMLError) do
@@ -32,7 +26,7 @@ class RelationTest < ActiveSupport::TestCase
 
   def test_from_xml_no_version
     no_version = "<osm><relation id='123' changeset='23' /></osm>"
-    assert_nothing_raised(OSM::APIBadXMLError) do
+    assert_nothing_raised do
       Relation.from_xml(no_version, true)
     end
     message_update = assert_raise(OSM::APIBadXMLError) do
@@ -45,7 +39,7 @@ class RelationTest < ActiveSupport::TestCase
     id_list = ["", "0", "00", "0.0", "a"]
     id_list.each do |id|
       zero_id = "<osm><relation id='#{id}' changeset='332' version='23' /></osm>"
-      assert_nothing_raised(OSM::APIBadUserInput) do
+      assert_nothing_raised do
         Relation.from_xml(zero_id, true)
       end
       message_update = assert_raise(OSM::APIBadUserInput) do