spec/crunchbase/acquisition_spec.rb in crunchbase_v2-1.0.0 vs spec/crunchbase/acquisition_spec.rb in crunchbase_v2-1.1.0

- old
+ new

@@ -1,26 +1,20 @@ require File.join(File.dirname(__FILE__), "..", "spec_helper.rb") module Crunchbase - describe Acquisition do + describe Acquisition, :vcr do + describe 'a list' do + subject { Acquisition.lists_for_permalink("facebook") } - describe "advanced indexing" do - before(:all) do - @all_acquisitions = Acquisition.lists_for_permalink("facebook") - end + its(:size) { should eq(49) } - it "should pull from web api" do - @all_acquisitions.per_page.should == 1000 - @all_acquisitions.current_page.should == 1 - @all_acquisitions.size.should == 49 - end + it_has_behavior 'pagination' end - - it "should pull from web api" do - acquisition = Acquisition.get("7a3d7915ed43073c0e4b5b0d7601def8") - acquisition.name.should == "Acquisition" - acquisition.permalink.should == "7a3d7915ed43073c0e4b5b0d7601def8" - end + describe 'an entity' do + subject { Acquisition.get("7a3d7915ed43073c0e4b5b0d7601def8") } + its(:name) { should eq('Acquisition') } + its(:permalink) { should eq('7a3d7915ed43073c0e4b5b0d7601def8') } + end end end