Sha256: 41f18fa83a124bc81529206fd0afa377fb9d376cffed26ef1bc45bb906efee92

Contents?: true

Size: 948 Bytes

Versions: 50

Compression:

Stored size: 948 Bytes

Contents

require 'spec_helper'

describe Dugway::Drops::ArtistDrop do
  let(:artist) { Dugway::Drops::ArtistDrop.new(Dugway.store.artists.first) }

  describe "#id" do
    it "should return the artist's id" do
      artist.id.should == 176141
    end
  end

  describe "#name" do
    it "should return the artist's name" do
      artist.name.should == 'Artist One'
    end
  end

  describe "#permalink" do
    it "should return the artist's permalink" do
      artist.permalink.should == 'artist-one'
    end
  end

  describe "#url" do
    it "should return the artist's url" do
      artist.url.should == '/artist/artist-one'
    end
  end

  describe "#products" do
    it "should return the artist's products" do
      products = artist.products
      products.should be_an_instance_of(Array)

      product = products.first
      product.should be_an_instance_of(Dugway::Drops::ProductDrop)
      product.name.should == 'My Product'
    end
  end
end

Version data entries

50 entries across 50 versions & 1 rubygems

Version Path
dugway-0.11.2 spec/units/dugway/liquid/drops/artist_drop_spec.rb
dugway-0.11.1 spec/units/dugway/liquid/drops/artist_drop_spec.rb
dugway-0.11.0 spec/units/dugway/liquid/drops/artist_drop_spec.rb
dugway-0.10.5 spec/units/dugway/liquid/drops/artist_drop_spec.rb
dugway-0.10.4 spec/units/dugway/liquid/drops/artist_drop_spec.rb
dugway-0.10.3 spec/units/dugway/liquid/drops/artist_drop_spec.rb
dugway-0.10.2 spec/units/dugway/liquid/drops/artist_drop_spec.rb
dugway-0.10.1 spec/units/dugway/liquid/drops/artist_drop_spec.rb
dugway-0.10.0 spec/units/dugway/liquid/drops/artist_drop_spec.rb
dugway-0.9.0 spec/units/dugway/liquid/drops/artist_drop_spec.rb
dugway-0.8.4 spec/units/dugway/liquid/drops/artist_drop_spec.rb
dugway-0.8.3 spec/units/dugway/liquid/drops/artist_drop_spec.rb
dugway-0.8.2 spec/units/dugway/liquid/drops/artist_drop_spec.rb
dugway-0.8.1 spec/units/dugway/liquid/drops/artist_drop_spec.rb
dugway-0.8.0 spec/units/dugway/liquid/drops/artist_drop_spec.rb
dugway-0.7.1 spec/units/dugway/liquid/drops/artist_drop_spec.rb
dugway-0.7.0 spec/units/dugway/liquid/drops/artist_drop_spec.rb
dugway-0.6.7 spec/units/dugway/liquid/drops/artist_drop_spec.rb
dugway-0.6.6 spec/units/dugway/liquid/drops/artist_drop_spec.rb
dugway-0.6.5 spec/units/dugway/liquid/drops/artist_drop_spec.rb