mirror of
https://github.com/stripe/stripe-ruby.git
synced 2025-12-11 00:02:39 -05:00
Tests for BankAccount#verify
This commit is contained in:
parent
cdc1165fc5
commit
7cd161dd03
21
test/stripe/bank_account_test.rb
Normal file
21
test/stripe/bank_account_test.rb
Normal file
@ -0,0 +1,21 @@
|
|||||||
|
require File.expand_path('../../test_helper', __FILE__)
|
||||||
|
|
||||||
|
module Stripe
|
||||||
|
class BankAccountTest < Test::Unit::TestCase
|
||||||
|
|
||||||
|
should 'be verifiable' do
|
||||||
|
bank = Stripe::BankAccount.construct_from({
|
||||||
|
:id => 'ba_foo',
|
||||||
|
:customer => 'cus_bar'
|
||||||
|
})
|
||||||
|
|
||||||
|
@mock.expects(:post).
|
||||||
|
once.
|
||||||
|
with('https://api.stripe.com/v1/customers/cus_bar/sources/ba_foo/verify', nil, 'amounts[]=1&amounts[]=2').
|
||||||
|
returns(make_response(:status => 'verified'))
|
||||||
|
|
||||||
|
bank.verify(:amounts => [1,2])
|
||||||
|
end
|
||||||
|
|
||||||
|
end
|
||||||
|
end
|
||||||
Loading…
x
Reference in New Issue
Block a user