def test_get_checkout_data_success(): client = AcmeClient() client.login(user, pwd) res1 = client.create_quote(test_request) quote_number = res1['quote_number'] res2 = client.get_checkout_data(quote_number) assert 'rates' in res2 assert 'total' in res2
def test_get_checkout_data_fails_no_auth(): client = AcmeClient() with pytest.raises(ClientUnauthorizedException): client.get_checkout_data(1)