Skip to content

Commit 9aec080

Browse files
adamchainzjpic
authored andcommitted
Test on Django 4.2
1 parent 66210bb commit 9aec080

File tree

4 files changed

+24
-3
lines changed

4 files changed

+24
-3
lines changed

.travis.yml

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -26,6 +26,12 @@ matrix:
2626
env: TOXENV=py39-dj41
2727
- python: 3.10
2828
env: TOXENV=py310-dj41
29+
- python: 3.8
30+
env: TOXENV=py38-dj42
31+
- python: 3.9
32+
env: TOXENV=py39-dj42
33+
- python: 3.10
34+
env: TOXENV=py310-dj42
2935
install:
3036
- travis_retry pip install -U pip
3137
- travis_retry pip install tox

setup.py

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,10 @@ def read(fname):
2727
long_description=read('README'),
2828
license='MIT',
2929
keywords='django autocomplete',
30-
install_requires=['six'],
30+
install_requires=[
31+
'django>=3.2',
32+
'six',
33+
],
3134
extras_require={
3235
'nested': ['django-nested-admin>=3.0.21'],
3336
'tags': ['django-taggit'],
@@ -39,6 +42,9 @@ def read(fname):
3942
'Environment :: Web Environment',
4043
'Framework :: Django',
4144
'Framework :: Django :: 3.2',
45+
'Framework :: Django :: 4.0',
46+
'Framework :: Django :: 4.1',
47+
'Framework :: Django :: 4.2',
4248
'Intended Audience :: Developers',
4349
'License :: OSI Approved :: MIT License',
4450
'Operating System :: OS Independent',

test_project/settings/base.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -161,7 +161,8 @@ def get_databases(base_dir):
161161
LANGUAGE_CODE = 'en-us'
162162
TIME_ZONE = 'UTC'
163163
USE_I18N = True
164-
USE_L10N = True
164+
if django.VERSION < (4, 0):
165+
USE_L10N = True
165166
USE_TZ = True
166167

167168
SITE_ID = 1

tox.ini

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,7 @@ envlist =
33
py{36,37,38,39,310,py3}-dj32
44
py{38,39,310,py3}-dj40
55
py{38,39,310,py3}-dj41
6+
py{38,39,310,py3}-dj42
67
py{38,39,310,py3}-djmain
78

89
[testenv]
@@ -19,10 +20,17 @@ deps =
1920
dj32: Django==3.2.*
2021
dj40: Django==4.0.*
2122
dj41: Django==4.1.*
23+
dj41: Django==4.2.*
2224
djmain: https://github.com/django/django/archive/main.tar.gz
2325
-rtest_project/requirements.txt
2426

25-
passenv = DISPLAY XAUTHORITY XDG_* PIP_* BROWSER MOZ_HEADLESS
27+
passenv =
28+
DISPLAY
29+
XAUTHORITY
30+
XDG_*
31+
PIP_*
32+
BROWSER
33+
MOZ_HEADLESS
2634

2735
[testenv:checkqa]
2836
changedir = {toxinidir}

0 commit comments

Comments
 (0)