Sha256: cf9d456bcb5419ca6bb058b7b359cb9eb83260996bd65cb683d43a7d0592efc7

Contents?: true

Size: 729 Bytes

Versions: 1

Compression:

Stored size: 729 Bytes

Contents

require "spec_helper"

module Sucker
  describe "Seller listing search" do
    use_vcr_cassette "integration/seller_listings_search", :record => :new_episodes

    let(:listings) do
      worker = Sucker.new(
        :locale => "us",
        :key    => amazon["key"],
        :secret => amazon["secret"])

      worker << {
        "Operation"   => "SellerListingSearch",
        "SellerId"    => "A2JYSO6W6KEP83" }

      worker.get.node("SellerListings").first
    end

    it "returns page count" do
      listings["TotalPages"].to_i.should be > 0
    end

    it "returns listings" do
      listings["SellerListing"].size.should be > 0
      listings["SellerListing"].first.has_key?("Price").should be_true
    end
  end
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
sucker-1.0.0.beta.2 spec/integration/seller_listing_search_spec.rb