# File test/models/serializable_test.rb, line 38 def assert_key(key, subject) assert subject.key?(key), "Expected #{subject.inspect} to have key #{key.inspect}" end
# File test/models/serializable_test.rb, line 42 def assert_no_key(key, subject) assert !subject.key?(key), "Expected #{subject.inspect} to not have key #{key.inspect}" end
# File test/models/serializable_test.rb, line 46 def from_json(options=nil) ActiveSupport::JSON.decode(@user.to_json(options))["user"] end