X-Git-Url: https://git.openstreetmap.org./rails.git/blobdiff_plain/0bbdadd727a37ee71d4a8c89b50ce2060d6a6240..68845eb7253cd3da14253e004fc1a4fc7eac2e5e:/test/controllers/api/nodes_controller_test.rb diff --git a/test/controllers/api/nodes_controller_test.rb b/test/controllers/api/nodes_controller_test.rb index 95658842b..2d827a077 100644 --- a/test/controllers/api/nodes_controller_test.rb +++ b/test/controllers/api/nodes_controller_test.rb @@ -138,7 +138,7 @@ module Api xml = "" put node_create_path, :params => xml, :headers => auth_header assert_response :bad_request, "node upload did not return bad_request status" - assert_equal ["NodeTag ", " v: is too long (maximum is 255 characters) (\"#{'x' * 256}\")"], @response.body.split(/[0-9]+,foo:/) + assert_match(/ v: is too long \(maximum is 255 characters\) /, @response.body) end def test_show @@ -258,8 +258,7 @@ module Api # valid delete should return the new version number, which should # be greater than the old version number - assert @response.body.to_i > node.version, - "delete request should return a new version number for node" + assert_operator @response.body.to_i, :>, node.version, "delete request should return a new version number for node" # deleting the same node twice doesn't work xml = xml_for_node(node)