Sha256: d37872e3fd702b67c3d10b1ba8d2e29c921a9962ec18da216b6c8420050c8086
Contents?: true
Size: 810 Bytes
Versions: 3
Compression:
Stored size: 810 Bytes
Contents
require './spec/spec_helper' describe Video do it "responds to" do Video.should respond_to(:find_by_listing_key) Video.new.should respond_to(:branded?) Video.new.should respond_to(:unbranded?) end it "has a type" do Video.new(:Type => "branded").branded?.should == true Video.new(:Type => "unbranded").branded?.should == false Video.new(:Type => "unbranded").unbranded?.should == true Video.new(:Type => "branded").unbranded?.should == false end describe "find videos by listing id" do before do stub_auth_request stub_api_get('/listings/1234/videos','listings/videos_index.json') end it "should get an array of videos" do p = Video.find_by_listing_key('1234') p.should be_an(Array) p.length.should == 2 end end end
Version data entries
3 entries across 3 versions & 1 rubygems
Version | Path |
---|---|
flexmls_api-0.7.3 | spec/unit/flexmls_api/models/video_spec.rb |
flexmls_api-0.7.5 | spec/unit/flexmls_api/models/video_spec.rb |
flexmls_api-0.7.0 | spec/unit/flexmls_api/models/video_spec.rb |