test_dir = os.path.dirname(__file__)
sys.path.insert(0, test_dir)
+import django
from django.test.utils import get_runner
from django.conf import settings
def runtests():
+ if django.VERSION >= (1, 7):
+ django.setup()
TestRunner = get_runner(settings)
test_runner = TestRunner(verbosity=1, interactive=True)
failures = test_runner.run_tests(
[tox]
-envlist = py27,py33,py34
+envlist =
+ py27-django15,
+ py33-django15,
+ py27-django16,
+ py33-django16,
+ py27-django17,
+ py33-django17,
+ py34-django17
[testenv]
-deps=-rrequirements.txt
-commands=python setup.py test
+commands = python setup.py test
+deps =
+ django-model-utils
+ Pillow
+
+setenv =
+ PYTHONPATH = {toxinidir}
+
+
+[testenv:py27-django15]
+basepython = python2.7
+deps =
+ Django>=1.5,<1.6
+ {[testenv]deps}
+
+[testenv:py33-django15]
+basepython = python3.3
+deps =
+ Django>=1.5,<1.6
+ {[testenv]deps}
+
+[testenv:py27-django16]
+basepython = python2.7
+deps =
+ Django>=1.6,<1.7
+ {[testenv]deps}
+
+[testenv:py33-django16]
+basepython = python3.3
+deps =
+ Django>=1.6,<1.7
+ {[testenv]deps}
+
+[testenv:py27-django17]
+basepython = python2.7
+deps =
+ Django>=1.7,<1.8
+ {[testenv]deps}
+
+[testenv:py33-django17]
+basepython = python3.3
+deps =
+ Django>=1.7,<1.8
+ {[testenv]deps}
+
+[testenv:py34-django17]
+basepython = python3.4
+deps =
+ Django>=1.7,<1.8
+ {[testenv]deps}