aboutsummaryrefslogtreecommitdiffstats
path: root/activeresource
diff options
context:
space:
mode:
Diffstat (limited to 'activeresource')
-rw-r--r--activeresource/test/cases/base_test.rb6
1 files changed, 5 insertions, 1 deletions
diff --git a/activeresource/test/cases/base_test.rb b/activeresource/test/cases/base_test.rb
index 31e0dc0abc..a424b2baf3 100644
--- a/activeresource/test/cases/base_test.rb
+++ b/activeresource/test/cases/base_test.rb
@@ -1022,7 +1022,11 @@ class BaseTest < Test::Unit::TestCase
joe = Person.find(6)
json = joe.encode
Person.format = :xml
- assert_equal json, '{"person":{"person":{"name":"Joe","id":6}}}'
+
+ assert_match %r{^\{"person":\{"person":\{}, json
+ assert_match %r{"id":6}, json
+ assert_match %r{"name":"Joe"}, json
+ assert_match %r{\}\}\}$}, json
end
def test_to_param_quacks_like_active_record