Sha256: 53243299270cb2438ff424620e0385da4c92e30f6e3e321a66aedaef865e0e06

Contents?: true

Size: 479 Bytes

Versions: 10

Compression:

Stored size: 479 Bytes

Contents

require 'spec_helper.rb'

describe Paypal::HttpError do
  it 'should have code, message and body' do
    error = Paypal::HttpError.new(400, 'BadRequest', 'You are bad man!')
    error.code.should == 400
    error.message.should == 'BadRequest'
    error.body.should == 'You are bad man!'
  end
end

describe Paypal::APIError do
  it 'should have raw response' do
    error = Paypal::APIError.new({:error => 'ERROR!!'})
    error.response.should == {:error => 'ERROR!!'}
  end
end

Version data entries

10 entries across 10 versions & 1 rubygems

Version Path
paypal-express-0.1.0 spec/paypal/exception_spec.rb
paypal-express-0.0.9 spec/paypal/exception_spec.rb
paypal-express-0.0.8 spec/paypal/exception_spec.rb
paypal-express-0.0.7 spec/paypal/exception_spec.rb
paypal-express-0.0.6 spec/paypal/exception_spec.rb
paypal-express-0.0.5 spec/paypal/exception_spec.rb
paypal-express-0.0.4 spec/paypal/exception_spec.rb
paypal-express-0.0.3 spec/paypal/exception_spec.rb
paypal-express-0.0.2 spec/paypal/exception_spec.rb
paypal-express-0.0.1 spec/paypal/exception_spec.rb