From e4a5951f12eb7b532d453112a6cc974b17426465 Mon Sep 17 00:00:00 2001 From: Ilan Steemers Date: Wed, 9 Sep 2015 18:59:24 +0200 Subject: [PATCH] Resets SQS conf in case of test failure --- django_q/tests/test_cluster.py | 2 ++ django_q/tests/test_scheduler.py | 4 ++++ 2 files changed, 6 insertions(+) diff --git a/django_q/tests/test_cluster.py b/django_q/tests/test_cluster.py index 3aa09c6..dcd5394 100644 --- a/django_q/tests/test_cluster.py +++ b/django_q/tests/test_cluster.py @@ -18,6 +18,7 @@ from django_q.status import Stat from django_q.brokers import get_broker from .tasks import multiply + class WordClass(object): def __init__(self): self.word_list = DEFAULT_WORDLIST @@ -30,6 +31,7 @@ class WordClass(object): def broker(): Conf.DISQUE_NODES = None Conf.IRON_MQ = None + Conf.SQS = None Conf.DJANGO_REDIS = 'default' return get_broker() diff --git a/django_q/tests/test_scheduler.py b/django_q/tests/test_scheduler.py index 2ee337a..4cf7fd3 100644 --- a/django_q/tests/test_scheduler.py +++ b/django_q/tests/test_scheduler.py @@ -14,6 +14,10 @@ from django_q.tasks import Schedule, fetch, schedule as create_schedule, queue_s @pytest.fixture def broker(): + Conf.DISQUE_NODES = None + Conf.IRON_MQ = None + Conf.SQS = None + Conf.DJANGO_REDIS = 'default' return get_broker()