diff --git a/tcms/core/tests/test_collectstatic.py b/tcms/core/tests/test_collectstatic.py index 22cf034493..009089b679 100644 --- a/tcms/core/tests/test_collectstatic.py +++ b/tcms/core/tests/test_collectstatic.py @@ -10,7 +10,7 @@ class TestCollectstatic(TestCase): """ Test manage.py collectstatic --noinput --link - with different versions of STATICFILES_STORAGE. See + with different versions of STORAGES["staticfiles"]. See https://github.com/sehmaschine/django-grappelli/issues/1022 """ @@ -23,7 +23,11 @@ class TestCollectstatic(TestCase): ) def test_collect_static(self, storage): # pylint: disable=no-self-use with override_settings( - STATICFILES_STORAGE=storage, + STORAGES={ + "staticfiles": { + "BACKEND": storage, + }, + }, STATIC_ROOT=tempfile.mkdtemp(), STATICFILES_DIRS=[ # pylint: disable=avoid-list-comprehension dir diff --git a/tcms/settings/devel.py b/tcms/settings/devel.py index 73aca8866e..cce1303e73 100644 --- a/tcms/settings/devel.py +++ b/tcms/settings/devel.py @@ -41,6 +41,8 @@ # http://docs.djangoproject.com/en/dev/ref/templates/api/#django-template-context-processors-debug INTERNAL_IPS = ("127.0.0.1",) -STATICFILES_STORAGE = "tcms.tests.storage.RaiseWhenFileNotFound" +STORAGES["staticfiles"][ # noqa: F405 + "BACKEND" +] = "tcms.tests.storage.RaiseWhenFileNotFound" ANONYMOUS_ANALYTICS = False