Sha256: c2ca32de32e728e68ab4fe558187e590c0ce6e548a13d3124ab138a9687a2716

Contents?: true

Size: 662 Bytes

Versions: 16

Compression:

Stored size: 662 Bytes

Contents

require File.expand_path(File.dirname(__FILE__) + "/../spec_helper")

describe ::Braintree::ExchangeRate do
  let(:rate_quote) do
    {
      id: "1234",
      base_amount: "10.00",
      exchange_rate: "74",
      quote_amount: "740"
    }
  end

  describe "#initialize" do
    it "initialize and sets the attributes" do
      exchange_rate = described_class.new(:gateway, rate_quote).inspect

      expect(exchange_rate).to include("@id=\"1234\"")
      expect(exchange_rate).to include("@base_amount=\"10.00\"")
      expect(exchange_rate).to include("@exchange_rate=\"74\"")
      expect(exchange_rate).to include("@quote_amount=\"740\"")
    end
  end
end

Version data entries

16 entries across 16 versions & 1 rubygems

Version Path
braintree-4.23.0 spec/unit/braintree/exchange_rate_spec.rb
braintree-4.22.0 spec/unit/braintree/exchange_rate_spec.rb
braintree-4.21.0 spec/unit/braintree/exchange_rate_spec.rb
braintree-4.20.0 spec/unit/braintree/exchange_rate_spec.rb
braintree-4.19.0 spec/unit/braintree/exchange_rate_spec.rb
braintree-4.18.0 spec/unit/braintree/exchange_rate_spec.rb
braintree-4.17.0 spec/unit/braintree/exchange_rate_spec.rb
braintree-4.16.0 spec/unit/braintree/exchange_rate_spec.rb
braintree-4.15.0 spec/unit/braintree/exchange_rate_spec.rb
braintree-4.14.0 spec/unit/braintree/exchange_rate_spec.rb
braintree-4.13.0 spec/unit/braintree/exchange_rate_spec.rb
braintree-4.12.0 spec/unit/braintree/exchange_rate_spec.rb
braintree-4.11.0 spec/unit/braintree/exchange_rate_spec.rb
braintree-4.10.0 spec/unit/braintree/exchange_rate_spec.rb
braintree-4.9.0 spec/unit/braintree/exchange_rate_spec.rb
braintree-4.8.0 spec/unit/braintree/exchange_rate_spec.rb