Sha256: c48d0a71942e28e72ff6128949fb0848c60fa40f03d76f904f0ea1b58589f19d

Contents?: true

Size: 693 Bytes

Versions: 6

Compression:

Stored size: 693 Bytes

Contents

require 'spec_helper'

module Fedex
  describe 'ServiceAvailability' do
    let(:fedex)  { Shipment.new(fedex_credentials) }
    let(:origin) do {:postal_code => '400012', :country_code => 'IN'} end
    let(:destination) do { :postal_code => '400020', :country_code => 'IN'} end
    let(:options) do {:origin => origin, :destination => destination, :ship_date => '2014-06-28', :carrier_code => 'FDXE'} end

    context 'Check Availability', :vcr do
      it "succeeds" do
        expect {
            @service_availability = fedex.service_availability(options)
          }.to_not raise_error

        expect(@service_availability.class).not_to eq(Fedex::RateError)
      end
    end
  end
end

Version data entries

6 entries across 6 versions & 1 rubygems

Version Path
fedex-3.10.11 spec/lib/fedex/service_availability_spec.rb
fedex-3.10.1 spec/lib/fedex/service_availability_spec.rb
fedex-3.10.0 spec/lib/fedex/service_availability_spec.rb
fedex-3.9.1 spec/lib/fedex/service_availability_spec.rb
fedex-3.9.0 spec/lib/fedex/service_availability_spec.rb
fedex-3.8.0 spec/lib/fedex/service_availability_spec.rb