spec/generate_spec.rb in jsonify-0.0.8 vs spec/generate_spec.rb in jsonify-0.0.9

- old
+ new

@@ -11,11 +11,11 @@ end it 'should build json' do json = Jsonify::Generate result = json.value links expected = '{"links":[{"rel":"foo","href":"goo"},{"rel":"bar","href":"baz"}]}' - JSON.parse(result.evaluate).should == JSON.parse(expected) + JSON.parse(result.to_json).should == JSON.parse(expected) end describe 'complex example' do let(:jsonifier) { Jsonify::Generate } @@ -27,9 +27,9 @@ jsonifier.object_value( {"rel" => "bar", "href" => "baz"} ) ]) } ) expected = "{\"links\":[{\"rel\":\"foo\",\"href\":\"goo\"},{\"rel\":\"bar\",\"href\":\"baz\"}]}" - JSON.parse(json.evaluate).should == JSON.parse(expected) + JSON.parse(json.to_json).should == JSON.parse(expected) end end end \ No newline at end of file