diff options
| author | Tim Graham <timograham@gmail.com> | 2017-06-01 13:26:37 -0400 |
|---|---|---|
| committer | Tim Graham <timograham@gmail.com> | 2017-06-01 13:30:08 -0400 |
| commit | 3cd9a4b1ea47614693619f56b4ee0d37244132a5 (patch) | |
| tree | 39220842a633f5272bab6838e36abaa9834a1ba4 /tests | |
| parent | 2134090e798bbc2d11c57c11f7e1c05dbcf1e39f (diff) | |
[1.11.x] Sorted imports per isort 4.2.9.
Backport of cde31daf8815e05b4b86b857b49fb0e31e1f0a38 from master
Diffstat (limited to 'tests')
| -rw-r--r-- | tests/base/models.py | 1 | ||||
| -rw-r--r-- | tests/check_framework/tests_1_10_compatibility.py | 5 | ||||
| -rw-r--r-- | tests/check_framework/tests_1_8_compatibility.py | 5 | ||||
| -rw-r--r-- | tests/foreign_object/tests.py | 1 | ||||
| -rw-r--r-- | tests/i18n/test_compilation.py | 5 | ||||
| -rw-r--r-- | tests/i18n/test_extraction.py | 5 | ||||
| -rw-r--r-- | tests/model_inheritance/models.py | 1 | ||||
| -rw-r--r-- | tests/model_options/models/tablespaces.py | 1 | ||||
| -rw-r--r-- | tests/prefetch_related/models.py | 2 | ||||
| -rw-r--r-- | tests/proxy_models/models.py | 1 | ||||
| -rw-r--r-- | tests/select_related/models.py | 1 | ||||
| -rw-r--r-- | tests/serializers/test_data.py | 1 | ||||
| -rw-r--r-- | tests/sessions_tests/tests.py | 10 | ||||
| -rw-r--r-- | tests/staticfiles_tests/test_storage.py | 5 | ||||
| -rw-r--r-- | tests/unmanaged_models/models.py | 1 |
15 files changed, 21 insertions, 24 deletions
diff --git a/tests/base/models.py b/tests/base/models.py index 4a8a2ffd81..7a6b114516 100644 --- a/tests/base/models.py +++ b/tests/base/models.py @@ -3,7 +3,6 @@ from __future__ import unicode_literals from django.db import models from django.utils import six - # The models definitions below used to crash. Generating models dynamically # at runtime is a bad idea because it pollutes the app registry. This doesn't # integrate well with the test suite but at least it prevents regressions. diff --git a/tests/check_framework/tests_1_10_compatibility.py b/tests/check_framework/tests_1_10_compatibility.py index 388ac1b024..e085f68881 100644 --- a/tests/check_framework/tests_1_10_compatibility.py +++ b/tests/check_framework/tests_1_10_compatibility.py @@ -1,5 +1,6 @@ -from django.core.checks.compatibility.django_1_10 import \ - check_duplicate_middleware_settings +from django.core.checks.compatibility.django_1_10 import ( + check_duplicate_middleware_settings, +) from django.test import SimpleTestCase from django.test.utils import override_settings diff --git a/tests/check_framework/tests_1_8_compatibility.py b/tests/check_framework/tests_1_8_compatibility.py index d8601b1064..c3865643b2 100644 --- a/tests/check_framework/tests_1_8_compatibility.py +++ b/tests/check_framework/tests_1_8_compatibility.py @@ -1,5 +1,6 @@ -from django.core.checks.compatibility.django_1_8_0 import \ - check_duplicate_template_settings +from django.core.checks.compatibility.django_1_8_0 import ( + check_duplicate_template_settings, +) from django.test import SimpleTestCase from django.test.utils import override_settings diff --git a/tests/foreign_object/tests.py b/tests/foreign_object/tests.py index 3c1f5bdfb4..e74732ab72 100644 --- a/tests/foreign_object/tests.py +++ b/tests/foreign_object/tests.py @@ -13,7 +13,6 @@ from .models import ( Group, Membership, NewsArticle, Person, ) - # Note that these tests are testing internal implementation details. # ForeignObject is not part of public API. diff --git a/tests/i18n/test_compilation.py b/tests/i18n/test_compilation.py index b33338800a..85d3b7939a 100644 --- a/tests/i18n/test_compilation.py +++ b/tests/i18n/test_compilation.py @@ -10,8 +10,9 @@ from subprocess import Popen from django.core.management import ( CommandError, call_command, execute_from_command_line, ) -from django.core.management.commands.makemessages import \ - Command as MakeMessagesCommand +from django.core.management.commands.makemessages import ( + Command as MakeMessagesCommand, +) from django.core.management.utils import find_command from django.test import SimpleTestCase, mock, override_settings from django.test.utils import captured_stderr, captured_stdout diff --git a/tests/i18n/test_extraction.py b/tests/i18n/test_extraction.py index 9311a1e7f0..3befcb7c8a 100644 --- a/tests/i18n/test_extraction.py +++ b/tests/i18n/test_extraction.py @@ -14,8 +14,9 @@ from admin_scripts.tests import AdminScriptTestCase from django.core import management from django.core.management import execute_from_command_line from django.core.management.base import CommandError -from django.core.management.commands.makemessages import \ - Command as MakeMessagesCommand +from django.core.management.commands.makemessages import ( + Command as MakeMessagesCommand, +) from django.core.management.utils import find_command from django.test import SimpleTestCase, mock, override_settings from django.test.utils import captured_stderr, captured_stdout diff --git a/tests/model_inheritance/models.py b/tests/model_inheritance/models.py index 45f22df0bc..659f0c5b22 100644 --- a/tests/model_inheritance/models.py +++ b/tests/model_inheritance/models.py @@ -16,7 +16,6 @@ from __future__ import unicode_literals from django.db import models from django.utils.encoding import python_2_unicode_compatible - # # Abstract base classes # diff --git a/tests/model_options/models/tablespaces.py b/tests/model_options/models/tablespaces.py index ec705b7b2d..0ee0e20ef4 100644 --- a/tests/model_options/models/tablespaces.py +++ b/tests/model_options/models/tablespaces.py @@ -1,6 +1,5 @@ from django.db import models - # Since the test database doesn't have tablespaces, it's impossible for Django # to create the tables for models where db_tablespace is set. To avoid this # problem, we mark the models as unmanaged, and temporarily revert them to diff --git a/tests/prefetch_related/models.py b/tests/prefetch_related/models.py index 6600418b8f..c5f895fe96 100644 --- a/tests/prefetch_related/models.py +++ b/tests/prefetch_related/models.py @@ -10,8 +10,6 @@ from django.utils.encoding import python_2_unicode_compatible from django.utils.functional import cached_property -# Basic tests - @python_2_unicode_compatible class Author(models.Model): name = models.CharField(max_length=50, unique=True) diff --git a/tests/proxy_models/models.py b/tests/proxy_models/models.py index 6960042d78..8b081f5290 100644 --- a/tests/proxy_models/models.py +++ b/tests/proxy_models/models.py @@ -7,7 +7,6 @@ providing a modified interface to the data from the base class. from django.db import models from django.utils.encoding import python_2_unicode_compatible - # A couple of managers for testing managing overriding in proxy model cases. diff --git a/tests/select_related/models.py b/tests/select_related/models.py index bef2873731..26bf34ebd1 100644 --- a/tests/select_related/models.py +++ b/tests/select_related/models.py @@ -14,7 +14,6 @@ from django.contrib.contenttypes.models import ContentType from django.db import models from django.utils.encoding import python_2_unicode_compatible - # Who remembers high school biology? diff --git a/tests/serializers/test_data.py b/tests/serializers/test_data.py index f9cb9582fe..cc42f2869a 100644 --- a/tests/serializers/test_data.py +++ b/tests/serializers/test_data.py @@ -32,7 +32,6 @@ from .models import ( ) from .tests import register_tests - # A set of functions that can be used to recreate # test data objects of various kinds. # The save method is a raw base model save, to make diff --git a/tests/sessions_tests/tests.py b/tests/sessions_tests/tests.py index 5ccccf699b..c15c39224b 100644 --- a/tests/sessions_tests/tests.py +++ b/tests/sessions_tests/tests.py @@ -10,12 +10,14 @@ from datetime import timedelta from django.conf import settings from django.contrib.sessions.backends.base import UpdateError from django.contrib.sessions.backends.cache import SessionStore as CacheSession -from django.contrib.sessions.backends.cached_db import \ - SessionStore as CacheDBSession +from django.contrib.sessions.backends.cached_db import ( + SessionStore as CacheDBSession, +) from django.contrib.sessions.backends.db import SessionStore as DatabaseSession from django.contrib.sessions.backends.file import SessionStore as FileSession -from django.contrib.sessions.backends.signed_cookies import \ - SessionStore as CookieSession +from django.contrib.sessions.backends.signed_cookies import ( + SessionStore as CookieSession, +) from django.contrib.sessions.exceptions import InvalidSessionKey from django.contrib.sessions.middleware import SessionMiddleware from django.contrib.sessions.models import Session diff --git a/tests/staticfiles_tests/test_storage.py b/tests/staticfiles_tests/test_storage.py index e06e54487e..d0dcafc123 100644 --- a/tests/staticfiles_tests/test_storage.py +++ b/tests/staticfiles_tests/test_storage.py @@ -8,8 +8,9 @@ import unittest from django.conf import settings from django.contrib.staticfiles import finders, storage -from django.contrib.staticfiles.management.commands.collectstatic import \ - Command as CollectstaticCommand +from django.contrib.staticfiles.management.commands.collectstatic import ( + Command as CollectstaticCommand, +) from django.core.cache.backends.base import BaseCache from django.core.management import call_command from django.test import override_settings diff --git a/tests/unmanaged_models/models.py b/tests/unmanaged_models/models.py index e925752a06..657d3d5be0 100644 --- a/tests/unmanaged_models/models.py +++ b/tests/unmanaged_models/models.py @@ -6,7 +6,6 @@ is generated for the table on various manage.py operations. from django.db import models from django.utils.encoding import python_2_unicode_compatible - # All of these models are created in the database by Django. |
