From a9a77cd6acaf5b2062d4f59c0b8bf6e817d299ac Mon Sep 17 00:00:00 2001 From: PCoder Date: Sun, 26 Nov 2017 00:06:50 +0100 Subject: [PATCH] Add Stripe key to skipif condition for CeleryTaskTestCase --- datacenterlight/tests.py | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/datacenterlight/tests.py b/datacenterlight/tests.py index e67dd1a7..d1ce9785 100644 --- a/datacenterlight/tests.py +++ b/datacenterlight/tests.py @@ -18,6 +18,11 @@ from utils.hosting_utils import get_vm_price from utils.stripe_utils import StripeUtils +@skipIf( + settings.STRIPE_API_PRIVATE_KEY_TEST is None or + settings.STRIPE_API_PRIVATE_KEY_TEST is "", + """Stripe details unavailable, so skipping CeleryTaskTestCase""" + ) class CeleryTaskTestCase(TestCase): @override_settings( task_eager_propagates=True,