test/stripe_test.rb in stripe-1.40.0 vs test/stripe_test.rb in stripe-1.41.0
- old
+ new
@@ -31,6 +31,21 @@
assert_equal 99, Stripe.max_network_retries
ensure
Stripe.max_network_retries = old
end
end
+
+ should "makes requests with the Stripe-Account header" do
+ response = make_account(
+ charges_enabled: false,
+ details_submitted: false,
+ email: "test+bindings@stripe.com"
+ )
+ Stripe.stripe_account = 'acct_1234'
+
+ Stripe.expects(:execute_request).with(
+ has_entry(:headers, has_entry(:stripe_account, 'acct_1234')),
+ ).returns(make_response(response))
+
+ Stripe.request(:post, '/v1/account', 'sk_live12334566')
+ end
end