Skip to content

Commit 0262af7

Browse files
Use public endpoint in stripe mock (#1505)
Co-authored-by: helenye-stripe <[email protected]>
1 parent 5291676 commit 0262af7

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

tests/api_resources/test_list_object.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -51,15 +51,15 @@ def test_create(self, http_client_mock, list_object):
5151
assert res.foo == "bar"
5252
assert res.stripe_account == "acct_123"
5353

54-
def test_create_maintains_list_properties(
54+
def test_retrieve_maintains_list_properties(
5555
self, http_client_mock, list_object
5656
):
5757
# Testing with real requests because our mock makes it impossible to
5858
# test otherwise
5959
charge = stripe.Charge.retrieve("ch_123", api_key="sk_test_custom")
60-
res = charge.refunds.create(amount=123)
60+
res = charge.refunds.retrieve("re_abc")
6161
http_client_mock.assert_requested(
62-
"post", path="/v1/charges/ch_123/refunds", post_data="amount=123"
62+
"get", path="/v1/charges/ch_123/refunds/re_abc"
6363
)
6464
assert res.api_key == "sk_test_custom"
6565

0 commit comments

Comments
 (0)