Skip to content

Commit

Permalink
Add support for retrieving a Checkout Session
Browse files Browse the repository at this point in the history
  • Loading branch information
remi-stripe committed Mar 19, 2019
1 parent 4a47d6a commit 36663ad
Showing 1 changed file with 8 additions and 1 deletion.
9 changes: 8 additions & 1 deletion tests/api_resources/checkout/test_session.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
import stripe


TEST_RESOURCE_ID = "loc_123"
TEST_RESOURCE_ID = "cs_123"


class TestSession(object):
Expand All @@ -27,3 +27,10 @@ def test_is_creatable(self, request_mock):
)
request_mock.assert_requested("post", "/v1/checkout/sessions")
assert isinstance(resource, stripe.checkout.Session)

def test_is_retrievable(self, request_mock):
resource = stripe.checkout.Session.retrieve(TEST_RESOURCE_ID)
request_mock.assert_requested(
"get", "/v1/checkout/sessions/%s" % TEST_RESOURCE_ID
)
assert isinstance(resource, stripe.checkout.Session)

0 comments on commit 36663ad

Please sign in to comment.