Skip to content
Browse files

Changes tests to use MultiJson instead of Crack

  • Loading branch information...
1 parent 9cfb5ac commit 4dec3561a9f6f197d2e960ab835c7d68863ba87c @vesan committed Apr 29, 2012
View
3 spec/kippt/clip_collection_spec.rb
@@ -1,9 +1,8 @@
require "spec_helper"
-require "crack/json"
require "kippt/clip_collection"
describe Kippt::ClipCollection do
- let(:data) { Crack::JSON.parse(fixture("clips.json").read) }
+ let(:data) { MultiJson.load(fixture("clips.json").read) }
subject { Kippt::ClipCollection.new(data) }
it_behaves_like "collection"
View
3 spec/kippt/clip_spec.rb
@@ -1,12 +1,11 @@
require "spec_helper"
-require "crack/json"
require "kippt/clip"
describe Kippt::Clip do
subject { Kippt::Clip.new(data, collection_resource) }
let(:collection_resource) { Kippt::Client.new(valid_user_credentials).clips }
- let(:data) { Crack::JSON.parse(fixture("clip.json").read) }
+ let(:data) { MultiJson.load(fixture("clip.json").read) }
let(:attributes) {
[:url_domain, :updated, :is_starred, :title,
:url, :notes, :created, :list, :id, :resource_uri]
View
3 spec/kippt/list_collection_spec.rb
@@ -1,8 +1,7 @@
require "spec_helper"
-require "crack/json"
describe Kippt::ListCollection do
- let(:data) { Crack::JSON.parse(fixture("lists.json").read) }
+ let(:data) { MultiJson.load(fixture("lists.json").read) }
subject { Kippt::ListCollection.new(data) }
it_behaves_like "collection"
View
3 spec/kippt/list_spec.rb
@@ -1,12 +1,11 @@
require "spec_helper"
-require "crack/json"
require "kippt/list"
describe Kippt::List do
subject { Kippt::List.new(data, collection_resource) }
let(:collection_resource) { Kippt::Client.new(valid_user_credentials).lists }
- let(:data) { Crack::JSON.parse(fixture("list.json").read) }
+ let(:data) { MultiJson.load(fixture("list.json").read) }
let(:attributes) {
[:id, :rss_url, :updated, :title,
:created, :slug, :resource_uri]

0 comments on commit 4dec356

Please sign in to comment.
Something went wrong with that request. Please try again.