Skip to content

Commit 0d5ca7b

Browse files
committed
Moved an import in an auth test; refs #23925.
This keeps tests/__init__.py from importing other modules and may fix a problem with test discovery revealed in formtools tests on Travis CI.
1 parent 9aeb917 commit 0d5ca7b

File tree

3 files changed

+3
-4
lines changed

3 files changed

+3
-4
lines changed

django/contrib/auth/tests/__init__.py

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1 @@
11
# The password for the fixture data users is 'password'
2-
3-
# For testing that auth backends can be referenced using a convenience import
4-
from django.contrib.auth.tests.test_auth_backends import ImportedModelBackend # NOQA
Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
# For testing that auth backends can be referenced using a convenience import
2+
from django.contrib.auth.tests.test_auth_backends import ImportedModelBackend # NOQA

django/contrib/auth/tests/test_auth_backends.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -620,7 +620,7 @@ class ImportedBackendTests(TestCase):
620620
as the one defined in AUTHENTICATION_BACKENDS setting.
621621
"""
622622

623-
backend = 'django.contrib.auth.tests.ImportedModelBackend'
623+
backend = 'django.contrib.auth.tests.backend_alias.ImportedModelBackend'
624624

625625
@override_settings(AUTHENTICATION_BACKENDS=(backend, ))
626626
def test_backend_path(self):

0 commit comments

Comments
 (0)