Refactor the from_xml methods to act on existing trace objects.
[rails.git] / test / controllers / trace_controller_test.rb
index b635f3e57909edb9f187b566b83ad1fba865182a..a23b5947359506b2f659ef211663066f86572739 100644 (file)
@@ -942,7 +942,10 @@ class TraceControllerTest < ActionController::TestCase
     assert_response :success
 
     updated = Trace.find(trace.id)
     assert_response :success
 
     updated = Trace.find(trace.id)
-    assert_equal trace.tags, updated.tags
+    # Ensure there's only one tag in the database after updating
+    assert_equal Tracetag.count, 1
+    # The new tag object might have a different id, so check the string representation
+    assert_equal trace.tagstring, updated.tagstring
   end
 
   # Check deleting a trace through the api
   end
 
   # Check deleting a trace through the api