mirror of
https://github.com/SectorLabs/django-localized-fields.git
synced 2025-10-28 17:58:58 +03:00
Make Django tests use USE_TZ = True to silence Django 5.x deprecation warning
This commit is contained in:
@@ -1,3 +1,4 @@
|
||||
import django
|
||||
import dj_database_url
|
||||
|
||||
DEBUG = True
|
||||
@@ -51,6 +52,12 @@ MIDDLEWARE = [
|
||||
'django.contrib.auth.middleware.AuthenticationMiddleware',
|
||||
]
|
||||
|
||||
# See: https://github.com/psycopg/psycopg2/issues/1293
|
||||
if django.VERSION >= (3, 1):
|
||||
USE_TZ = True
|
||||
USE_I18N = True
|
||||
TIME_ZONE = 'UTC'
|
||||
|
||||
# set to a lower number than the default, since
|
||||
# we want the tests to be fast, default is 100
|
||||
LOCALIZED_FIELDS_MAX_RETRIES = 3
|
||||
|
||||
Reference in New Issue
Block a user