11[tox]
22envlist =
33 py27-django{111}
4- py35-django{111,20}
5- py37-django{111,20}
4+ py35-django{111,20,21,22}
5+ py36-django{111,20,21,22}
6+ py37-django{111,20,21,22}
67 pypy-django{111}
7-
8+ pypy3-django{111,20,21,22}
89 flake8
910 flakeplus
1011 apicheck
@@ -26,14 +27,13 @@ deps=
2627
2728 cov: -r{toxinidir}/requirements/test-django111.txt
2829
29- django20: -r{toxinidir}/requirements/test-django20.txt
3030 django111: -r{toxinidir}/requirements/test-django111.txt
31+ django20: -r{toxinidir}/requirements/test-django20.txt
32+ django21: django>=2.1<2.2
3133 django22: -r{toxinidir}/requirements/test-django22.txt
3234
3335 py{27,py}: -r{toxinidir}/requirements/python2.txt
34- py{35,37}: -r{toxinidir}/requirements/python3.txt
35-
36- py{27,35,37,py},cov: ephem
36+ py{35,36,37,py3}: -r{toxinidir}/requirements/python3.txt
3737
3838 linkcheck,apicheck: -r{toxinidir}/requirements/docs.txt
3939 flake8,flakeplus,pydocstyle: -r{toxinidir}/requirements/pkgutils.txt
@@ -42,33 +42,97 @@ recreate = False
4242commands =
4343 pip list
4444 py.test -xv
45- # ensure we can migrate up, back, and up again
45+
46+ [testenv:upgradebeat111]
47+ basepython = python2.7
48+ whitelist_externals = *
49+ setenv =
50+ GIT_TAG = v1.1.1
51+ commands =
52+ # must use older versions for starting with older celery-beat
53+ pip install " django>=1.11.17,<2.0"
54+ pip install " celery<5.0.0"
55+ pip list
56+ # save current hash so we can come back to it
57+ bash -c " git rev-parse HEAD > commit.hash"
58+ # first install our starting version
59+ git fetch --tags
60+ git checkout {env:GIT_TAG}
61+ python manage.py migrate django_celery_beat
62+ # now return to previous hash and ensure all migrations continue to work
63+ bash -c " cat commit.hash | git checkout -"
4664 python manage.py migrate django_celery_beat
4765 python manage.py migrate django_celery_beat 0001
4866 python manage.py migrate django_celery_beat
4967
50- [testenv:python37 ]
51- basepython = python3 .7
68+ [testenv:upgradebeat120 ]
69+ basepython = python2 .7
5270whitelist_externals = *
71+ setenv =
72+ GIT_TAG = v1.2.0
5373commands =
54- # for ubutu xenial we must fix erlang for rabbitmq-server to work
55- sudo apt install -y wget
56- wget http://packages.erlang-solutions.com/ubuntu/erlang_solutions.asc
57- sudo apt-key add erlang_solutions.asc
58- sudo apt update
59- sudo apt install -y erlang
60- sudo apt install -y erlang-nox
61- sudo apt install -y rabbitmq-server
62- sudo /etc/init.d/rabbitmq-server start
63- sudo /etc/init.d/rabbitmq-server status
64-
65- pip install ephem
66- pip install -U https://github.com/celery/celery/zipball/master# egg=celery
67- pip install -U https://github.com/celery/kombu/zipball/master# egg=kombu
74+ # must use older versions for starting with older celery-beat
75+ pip install " django>=1.11.17,<2.0"
76+ pip install " celery<5.0.0"
77+ pip list
78+ # save current hash so we can come back to it
79+ bash -c " git rev-parse HEAD > commit.hash"
80+ # first install our starting version
81+ git fetch --tags
82+ git checkout {env:GIT_TAG}
83+ python manage.py migrate django_celery_beat
84+ # now return to previous hash and ensure all migrations continue to work
85+ bash -c " cat commit.hash | git checkout -"
86+ python manage.py migrate django_celery_beat
87+ python manage.py migrate django_celery_beat 0001
88+ python manage.py migrate django_celery_beat
6889
90+ [testenv:upgradebeat130]
91+ basepython = python3.5
92+ setenv =
93+ GIT_TAG = v1.3.0
94+ whitelist_externals = *
95+ commands =
96+ # must use older versions for starting with older celery-beat
97+ pip install " django>=1.11.17,<2.0"
98+ pip install " celery<5.0.0"
6999 pip list
70- py.test -xv
71- # ensure we can migrate up, back, and up again
100+ # save current hash so we can come back to it
101+ bash -c " git rev-parse HEAD > commit.hash"
102+ # first install our starting version
103+ git fetch --tags
104+ git checkout {env:GIT_TAG}
105+ # run the migration for the older version
106+ python manage.py migrate django_celery_beat
107+ # now return to previous hash and ensure all migrations continue to work
108+ bash -c " cat commit.hash | git checkout -"
109+ pip install " django>=2.0.0"
110+ # now make sure migrations still work backward and forward
111+ python manage.py migrate django_celery_beat
112+ python manage.py migrate django_celery_beat 0001
113+ python manage.py migrate django_celery_beat
114+
115+ [testenv:upgradebeat140]
116+ basepython = python3.5
117+ whitelist_externals = *
118+ setenv =
119+ GIT_TAG = v1.4.0
120+ commands =
121+ # must use older versions for starting with older celery-beat
122+ pip install " django>=1.11.17,<2.0"
123+ pip install " celery<5.0.0"
124+ pip list
125+ # save current hash so we can come back to it
126+ bash -c " git rev-parse HEAD > commit.hash"
127+ # first install our starting version
128+ git fetch --tags
129+ git checkout {env:GIT_TAG}
130+ # run the migration for the older version
131+ python manage.py migrate django_celery_beat
132+ # now return to previous hash and ensure all migrations continue to work
133+ bash -c " cat commit.hash | git checkout -"
134+ pip install " django>=2.0.0"
135+ # now make sure migrations still work backward and forward
72136 python manage.py migrate django_celery_beat
73137 python manage.py migrate django_celery_beat 0001
74138 python manage.py migrate django_celery_beat
0 commit comments