Sha256: 05cccffa9962c41195a4b9427cfd763c82cdfb8ba5eaa4a4a01eab9bf8aa6efe

Contents?: true

Size: 687 Bytes

Versions: 15

Compression:

Stored size: 687 Bytes

Contents

require 'spec_helper'

module GoTransverseTractApi

  RSpec.describe Product::Product do
    before(:each) { http_auth }

    context ".find_all" do
      it "returns all products" do
        data = described_class.find_all
        expect(data.count).to be >= 0
      end
    end

    context ".find_by_eid" do
      it "returns a product for the given eid" do
        data = described_class.find_by_eid(0)
        expect(data['eid']).to be_nil 
      end
    end

    context ".find_by_name" do
      it "returns a product for the given name" do
        data = described_class.find_by_name('Postcards 1st Class', 'DEEP')
        expect(data).to_not be_nil 
      end
    end
  end
end

Version data entries

15 entries across 15 versions & 1 rubygems

Version Path
gotransverse-tract-api-0.7.4 spec/gotransverse-tract-api/product/product_spec.rb
gotransverse-tract-api-0.7.3 spec/gotransverse-tract-api/product/product_spec.rb
gotransverse-tract-api-0.7.2 spec/gotransverse-tract-api/product/product_spec.rb
gotransverse-tract-api-0.7.1 spec/gotransverse-tract-api/product/product_spec.rb
gotransverse-tract-api-0.7.0 spec/gotransverse-tract-api/product/product_spec.rb
gotransverse-tract-api-0.6.7 spec/gotransverse-tract-api/product/product_spec.rb
gotransverse-tract-api-0.6.6 spec/gotransverse-tract-api/product/product_spec.rb
gotransverse-tract-api-0.6.5 spec/gotransverse-tract-api/product/product_spec.rb
gotransverse-tract-api-0.6.4 spec/gotransverse-tract-api/product/product_spec.rb
gotransverse-tract-api-0.6.3 spec/gotransverse-tract-api/product/product_spec.rb
gotransverse-tract-api-0.6.2 spec/gotransverse-tract-api/product/product_spec.rb
gotransverse-tract-api-0.6.1 spec/gotransverse-tract-api/product/product_spec.rb
gotransverse-tract-api-0.6.0 spec/gotransverse-tract-api/product/product_spec.rb
gotransverse-tract-api-0.5.3 spec/gotransverse-tract-api/product/product_spec.rb
gotransverse-tract-api-0.5.2 spec/gotransverse-tract-api/product/product_spec.rb