From da6fc8c4685aba30ef4cbf1dfe07fba43e068557 Mon Sep 17 00:00:00 2001 From: salman2013 Date: Mon, 15 Jan 2024 12:26:24 +0500 Subject: [PATCH] chore: fix test cases --- ecommerce/extensions/payment/processors/stripe.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/ecommerce/extensions/payment/processors/stripe.py b/ecommerce/extensions/payment/processors/stripe.py index ae62818ecf5..d210d73200a 100644 --- a/ecommerce/extensions/payment/processors/stripe.py +++ b/ecommerce/extensions/payment/processors/stripe.py @@ -185,6 +185,7 @@ def handle_processor_response(self, response, basket=None): raise # proceed only if payment went through + # pylint: disable=E1136 assert confirm_api_response['status'] == "succeeded" self.record_processor_response(confirm_api_response, transaction_id=payment_intent_id, basket=basket) @@ -197,6 +198,7 @@ def handle_processor_response(self, response, basket=None): total = basket.total_incl_tax currency = basket.currency + # pylint: disable=E1136 card_object = confirm_api_response['charges']['data'][0]['payment_method_details']['card'] card_number = card_object['last4'] card_type = STRIPE_CARD_TYPE_MAP.get(card_object['brand'])