Sha256: 8ef3cb0daa2e9627cc81871129dd99315d4f1b4b4dc2bbc2a1f7a9ddd1410ed0

Contents?: true

Size: 511 Bytes

Versions: 7

Compression:

Stored size: 511 Bytes

Contents

require "support"

class TestForex < Omise::Test
  setup do
    @forex = Omise::Forex.from("USD")
  end

  def test_that_we_can_retrieve_a_forex
    forex = Omise::Forex.from("usd")

    assert_instance_of Omise::Forex, forex
  end

  def test_that_we_can_retrieve_a_forex_by_passing_symbol
    forex = Omise::Forex.from(:usd)

    assert_instance_of Omise::Forex, forex
  end

  def test_that_we_can_reload_a_forex
    @forex.attributes.taint
    @forex.reload

    refute @forex.attributes.tainted?
  end
end

Version data entries

7 entries across 7 versions & 1 rubygems

Version Path
omise-0.10.0 test/omise/test_forex.rb
omise-0.9.1 test/omise/test_forex.rb
omise-0.9.0 test/omise/test_forex.rb
omise-0.7.2 test/omise/test_forex.rb
omise-0.8.0 test/omise/test_forex.rb
omise-0.7.1 test/omise/test_forex.rb
omise-0.7.0 test/omise/test_forex.rb