From 452f53f8994c92314c9122342e51dccb68dab8e3 Mon Sep 17 00:00:00 2001 From: Ilan Steemers Date: Sun, 30 Aug 2015 20:57:05 +0200 Subject: [PATCH] New container build on Travis --- .travis.yml | 9 +++++++-- django_q/tests/test_brokers.py | 5 ++++- 2 files changed, 11 insertions(+), 3 deletions(-) diff --git a/.travis.yml b/.travis.yml index 663833c..208212f 100644 --- a/.travis.yml +++ b/.travis.yml @@ -11,8 +11,13 @@ env: - DJANGO=1.8.4 - DJANGO=1.7.10 +sudo: false +addons: + apt: + packages: + - tcl8.5 + before_script: - - sudo apt-get install tcl8.5 - git clone https://github.com/antirez/disque.git disque_server - "cd disque_server/src && make && PREFIX=../ make install && cd -" - "./disque_server/bin/disque-server &" @@ -25,7 +30,7 @@ install: - python setup.py install script: - - coverage run --source=django_q -m py.test + - coverage run --source=django_q -m py.testsudo: false - sphinx-build -b html -d docs/_build/doctrees -nW docs docs/_build/html after_success: diff --git a/django_q/tests/test_brokers.py b/django_q/tests/test_brokers.py index 5c2020c..0005d4f 100644 --- a/django_q/tests/test_brokers.py +++ b/django_q/tests/test_brokers.py @@ -26,6 +26,8 @@ def test_redis(): broker = get_broker() with pytest.raises(Exception): broker.ping() + Conf.REDIS = None + Conf.DJANGO_REDIS = 'default' def test_disque(): @@ -57,5 +59,6 @@ def test_disque(): Conf.DISQUE = ['127.0.0.1:7712', '127.0.0.1:7713'] with pytest.raises(ConnectionError): broker.get_connection() - # back to djangoredis + # back to django-redis + Conf.DISQUE = None Conf.DJANGO_REDIS = 'default'