Removed import * in tests.
Thanks to flake8 path/to/file.py | awk -F ' ' '{ print $5 }' | sort | uniq
This commit is contained in:
parent
2110b31365
commit
8e2029f8dd
|
@ -4,4 +4,4 @@ warnings.warn(
|
|||
"The django.contrib.admin.util module has been renamed. "
|
||||
"Use django.contrib.admin.utils instead.", PendingDeprecationWarning)
|
||||
|
||||
from django.contrib.admin.utils import *
|
||||
from django.contrib.admin.utils import * # NOQA
|
||||
|
|
|
@ -12,7 +12,9 @@ from django.test import TestCase
|
|||
from django.test.utils import override_settings
|
||||
from django.utils._os import upath
|
||||
|
||||
from django.contrib.formtools.tests.forms import *
|
||||
from django.contrib.formtools.tests.forms import (
|
||||
HashTestBlankForm, HashTestForm, TestForm,
|
||||
)
|
||||
|
||||
success_string = "Done was called!"
|
||||
success_string_encoded = success_string.encode()
|
||||
|
|
|
@ -4,4 +4,4 @@ warnings.warn(
|
|||
"The django.contrib.gis.db.backends.util module has been renamed. "
|
||||
"Use django.contrib.gis.db.backends.utils instead.", PendingDeprecationWarning)
|
||||
|
||||
from django.contrib.gis.db.backends.utils import *
|
||||
from django.contrib.gis.db.backends.utils import * # NOQA
|
||||
|
|
|
@ -8,7 +8,7 @@ from unittest import skipUnless
|
|||
from .. import HAS_GEOS
|
||||
|
||||
if HAS_GEOS:
|
||||
from .. import *
|
||||
from .. import fromstr, LinearRing, LineString, MultiPoint, Point, Polygon
|
||||
from ..error import GEOSIndexError
|
||||
|
||||
|
||||
|
|
|
@ -3,7 +3,7 @@ from __future__ import unicode_literals
|
|||
|
||||
import unittest
|
||||
|
||||
from django.contrib.webdesign.lorem_ipsum import *
|
||||
from django.contrib.webdesign.lorem_ipsum import paragraphs, words
|
||||
from django.template import loader, Context
|
||||
|
||||
|
||||
|
|
|
@ -4,4 +4,4 @@ warnings.warn(
|
|||
"The django.db.backends.util module has been renamed. "
|
||||
"Use django.db.backends.utils instead.", PendingDeprecationWarning)
|
||||
|
||||
from django.db.backends.utils import *
|
||||
from django.db.backends.utils import * # NOQA
|
||||
|
|
|
@ -4,4 +4,4 @@ warnings.warn(
|
|||
"The django.forms.util module has been renamed. "
|
||||
"Use django.forms.utils instead.", PendingDeprecationWarning)
|
||||
|
||||
from django.forms.utils import *
|
||||
from django.forms.utils import * # NOQA
|
||||
|
|
|
@ -1,7 +1,15 @@
|
|||
from django.contrib import admin
|
||||
from django import forms
|
||||
|
||||
from .models import *
|
||||
from .models import (
|
||||
Author, BinaryTree, CapoFamiglia, Chapter, ChildModel1, ChildModel2,
|
||||
Consigliere, EditablePKBook, ExtraTerrestrial, Fashionista, Holder,
|
||||
Holder2, Holder3, Holder4, Inner, Inner2, Inner3, Inner4Stacked,
|
||||
Inner4Tabular, NonAutoPKBook, Novel, ParentModelWithCustomPk, Poll,
|
||||
Profile, ProfileCollection, Question, ReadOnlyInline, ShoppingWeakness,
|
||||
Sighting, SomeChildModel, SomeParentModel, SottoCapo, Title,
|
||||
TitleCollection,
|
||||
)
|
||||
|
||||
site = admin.AdminSite(name="admin")
|
||||
|
||||
|
|
|
@ -5,7 +5,17 @@ import datetime
|
|||
import decimal
|
||||
import unittest
|
||||
|
||||
from django.template.defaultfilters import *
|
||||
from django.template.defaultfilters import (
|
||||
add, addslashes, capfirst, center, cut, date, default, default_if_none,
|
||||
dictsort, dictsortreversed, divisibleby, escape, escapejs_filter,
|
||||
filesizeformat, first, fix_ampersands_filter, floatformat, force_escape,
|
||||
get_digit, iriencode, join, length, length_is, linebreaksbr,
|
||||
linebreaks_filter, linenumbers, ljust, lower, make_list,
|
||||
phone2numeric_filter, pluralize, removetags, rjust, slice_filter, slugify,
|
||||
stringformat, striptags, time, timesince_filter, timeuntil_filter, title,
|
||||
truncatewords, truncatewords_html, unordered_list, upper, urlencode,
|
||||
urlize, urlizetrunc, wordcount, wordwrap, yesno,
|
||||
)
|
||||
from django.test import TestCase
|
||||
from django.utils import six
|
||||
from django.utils import translation
|
||||
|
|
|
@ -4,7 +4,13 @@ from __future__ import unicode_literals
|
|||
import warnings
|
||||
|
||||
from django.core.files.uploadedfile import SimpleUploadedFile
|
||||
from django.forms import *
|
||||
from django.forms import (
|
||||
BooleanField, CharField, ChoiceField, DateField, DateTimeField,
|
||||
DecimalField, EmailField, FileField, FloatField, Form,
|
||||
GenericIPAddressField, IntegerField, IPAddressField, ModelChoiceField,
|
||||
ModelMultipleChoiceField, MultipleChoiceField, RegexField,
|
||||
SplitDateTimeField, TimeField, URLField, utils, ValidationError,
|
||||
)
|
||||
from django.test import TestCase
|
||||
from django.utils.safestring import mark_safe
|
||||
from django.utils.encoding import python_2_unicode_compatible
|
||||
|
|
|
@ -4,7 +4,12 @@ from __future__ import unicode_literals
|
|||
import datetime
|
||||
import warnings
|
||||
|
||||
from django.forms import *
|
||||
from django.forms import (
|
||||
CharField, DateField, EmailField, FileField, Form, GenericIPAddressField,
|
||||
HiddenInput, ImageField, IPAddressField, MultipleChoiceField,
|
||||
MultiValueField, MultiWidget, PasswordInput, SelectMultiple, SlugField,
|
||||
SplitDateTimeField, SplitDateTimeWidget, TextInput, URLField,
|
||||
)
|
||||
from django.forms.extras import SelectDateWidget
|
||||
from django.forms.utils import ErrorList
|
||||
from django.test import TestCase
|
||||
|
|
|
@ -33,7 +33,14 @@ import os
|
|||
from decimal import Decimal
|
||||
|
||||
from django.core.files.uploadedfile import SimpleUploadedFile
|
||||
from django.forms import *
|
||||
from django.forms import (
|
||||
BooleanField, CharField, ChoiceField, ComboField, DateField, DateTimeField,
|
||||
DecimalField, EmailField, Field, FileField, FilePathField, FloatField,
|
||||
Form, forms, HiddenInput, IntegerField, MultipleChoiceField,
|
||||
NullBooleanField, NumberInput, PasswordInput, RadioSelect, RegexField,
|
||||
SplitDateTimeField, TextInput, TimeField, TypedChoiceField,
|
||||
TypedMultipleChoiceField, URLField, ValidationError, Widget,
|
||||
)
|
||||
from django.test import SimpleTestCase
|
||||
from django.utils import formats
|
||||
from django.utils import six
|
||||
|
|
|
@ -7,7 +7,13 @@ import warnings
|
|||
|
||||
from django.core.files.uploadedfile import SimpleUploadedFile
|
||||
from django.core.validators import RegexValidator
|
||||
from django.forms import *
|
||||
from django.forms import (
|
||||
BooleanField, CharField, CheckboxSelectMultiple, ChoiceField, DateField,
|
||||
EmailField, FileField, FloatField, Form, forms, HiddenInput, IntegerField,
|
||||
MultipleChoiceField, MultipleHiddenInput, MultiValueField,
|
||||
NullBooleanField, PasswordInput, RadioSelect, Select, SplitDateTimeField,
|
||||
Textarea, TextInput, ValidationError, widgets,
|
||||
)
|
||||
from django.http import QueryDict
|
||||
from django.template import Template, Context
|
||||
from django.test import TestCase
|
||||
|
|
|
@ -3,7 +3,11 @@ from __future__ import unicode_literals
|
|||
|
||||
import warnings
|
||||
|
||||
from django.forms import *
|
||||
from django.forms import (
|
||||
CharField, ChoiceField, Form, HiddenInput, IntegerField, ModelForm,
|
||||
ModelMultipleChoiceField, MultipleChoiceField, RadioSelect, Select,
|
||||
TextInput,
|
||||
)
|
||||
from django.test import TestCase
|
||||
from django.utils.translation import ugettext_lazy, override
|
||||
|
||||
|
|
|
@ -7,7 +7,13 @@ import datetime
|
|||
from django.contrib.admin.tests import AdminSeleniumWebDriverTestCase
|
||||
from django.core.files.uploadedfile import SimpleUploadedFile
|
||||
from django.core.urlresolvers import reverse
|
||||
from django.forms import *
|
||||
from django.forms import (
|
||||
BooleanField, CheckboxInput, CheckboxSelectMultiple, ChoiceField,
|
||||
ClearableFileInput, DateInput, DateTimeField, DateTimeInput, FileInput,
|
||||
Form, HiddenInput, MultipleHiddenInput, MultiWidget, NullBooleanSelect,
|
||||
PasswordInput, RadioSelect, Select, SelectMultiple, SplitDateTimeWidget,
|
||||
Textarea, TextInput, TimeInput,
|
||||
)
|
||||
from django.forms.widgets import RadioFieldRenderer
|
||||
from django.utils import formats
|
||||
from django.utils.safestring import mark_safe
|
||||
|
|
|
@ -7,7 +7,13 @@ import types
|
|||
from unittest import TestCase
|
||||
|
||||
from django.core.exceptions import ValidationError
|
||||
from django.core.validators import *
|
||||
from django.core.validators import (
|
||||
BaseValidator, EmailValidator, MaxLengthValidator, MaxValueValidator,
|
||||
MinLengthValidator, MinValueValidator, RegexValidator, URLValidator,
|
||||
validate_comma_separated_integer_list, validate_email, validate_integer,
|
||||
validate_ipv46_address, validate_ipv4_address, validate_ipv6_address,
|
||||
validate_slug,
|
||||
)
|
||||
from django.test.utils import str_prefix
|
||||
|
||||
|
||||
|
|
Loading…
Reference in New Issue