stripe-ruby/test/stripe/exchange_rate_test.rb
Brandur 85c811a18f Remove manual exchange rate stubbing
stripe-mock 0.4.0 comes with the up-to-date exchange rates API. Here we
bump the required version and remove the manual exchange rate stubbing
in stripe-ruby's test suite.
2017-10-31 09:17:51 -07:00

19 lines
593 B
Ruby

require File.expand_path("../../test_helper", __FILE__)
module Stripe
class ExchangeRateTest < Test::Unit::TestCase
should "be listable" do
list_rates = Stripe::ExchangeRate.list
assert_requested :get, "#{Stripe.api_base}/v1/exchange_rates"
assert list_rates.data.is_a?(Array)
assert list_rates.data.first.is_a?(Stripe::ExchangeRate)
end
should "be retrievable" do
rates = Stripe::ExchangeRate.retrieve("usd")
assert_requested :get, "#{Stripe.api_base}/v1/exchange_rates/usd"
assert rates.is_a?(Stripe::ExchangeRate)
end
end
end