Skip to content

Commit b1c94c6

Browse files
Zac-HDalexwlchan
authored andcommitted
Test Django 1.11 on Python 2
We don't want to stop testing Django on Python2 entirely.
1 parent c9d60d9 commit b1c94c6

File tree

1 file changed

+7
-4
lines changed

1 file changed

+7
-4
lines changed

scripts/basic-test.sh

+7-4
Original file line numberDiff line numberDiff line change
@@ -57,12 +57,15 @@ $PYTEST tests/fakefactory/
5757
pip uninstall -y faker
5858

5959
if [ "$(python -c 'import platform; print(platform.python_implementation())')" != "PyPy" ]; then
60-
if [ "$(python -c 'import sys; print(sys.version_info[:2] >= (3, 4))')" == "True" ] ; then
60+
if [ "$(python -c 'import sys; print(sys.version_info[0] == 3)')" = "True" ] ; then
6161
pip install .[django]
62-
HYPOTHESIS_DJANGO_USETZ=TRUE python -m tests.django.manage test tests.django
63-
HYPOTHESIS_DJANGO_USETZ=FALSE python -m tests.django.manage test tests.django
64-
pip uninstall -y django
62+
else
63+
pip install django~=1.11.8
64+
pip install pytz
6565
fi
66+
HYPOTHESIS_DJANGO_USETZ=TRUE python -m tests.django.manage test tests.django
67+
HYPOTHESIS_DJANGO_USETZ=FALSE python -m tests.django.manage test tests.django
68+
pip uninstall -y django pytz
6669

6770
if [ "$(python -c 'import sys; print(sys.version_info[:2] in ((2, 7), (3, 6)))')" = "True" ] ; then
6871
pip install numpy

0 commit comments

Comments
 (0)