summaryrefslogtreecommitdiff
path: root/tests/admin_views/admin.py
diff options
context:
space:
mode:
Diffstat (limited to 'tests/admin_views/admin.py')
-rw-r--r--tests/admin_views/admin.py51
1 files changed, 25 insertions, 26 deletions
diff --git a/tests/admin_views/admin.py b/tests/admin_views/admin.py
index dd49a0c0da..c044a6ac21 100644
--- a/tests/admin_views/admin.py
+++ b/tests/admin_views/admin.py
@@ -1,45 +1,46 @@
# -*- coding: utf-8 -*-
from __future__ import unicode_literals
-import tempfile
import os
+import tempfile
from wsgiref.util import FileWrapper
from django import forms
+from django.conf.urls import url
from django.contrib import admin
+from django.contrib.admin import BooleanFieldListFilter
from django.contrib.admin.views.main import ChangeList
+from django.contrib.auth.admin import GroupAdmin, UserAdmin
+from django.contrib.auth.models import Group, User
from django.core.exceptions import ValidationError
from django.core.files.storage import FileSystemStorage
from django.core.mail import EmailMessage
-from django.conf.urls import url
from django.forms.models import BaseModelFormSet
from django.http import HttpResponse, StreamingHttpResponse
-from django.contrib.admin import BooleanFieldListFilter
from django.utils.safestring import mark_safe
from django.utils.six import StringIO
from .models import (
- Article, Chapter, Child, Parent, Picture, Widget,
- DooHickey, Grommet, Whatsit, FancyDoodad, Category, Link,
- PrePopulatedPost, PrePopulatedSubPost, CustomArticle, Section,
- ModelWithStringPrimaryKey, Color, Thing, Actor, Inquisition, Sketch,
- Person, Persona, FooAccount, BarAccount, Subscriber, ExternalSubscriber,
- OldSubscriber, Podcast, Vodcast, EmptyModel, Fabric, Gallery, Language,
- Recommendation, Recommender, Collector, Post, Gadget, Villain,
- SuperVillain, Plot, PlotDetails, CyclicOne, CyclicTwo, WorkHour,
- Reservation, FoodDelivery, RowLevelChangePermissionModel, Paper,
- CoverLetter, Story, OtherStory, Book, Promo, ChapterXtra1, Pizza, Topping,
- Album, Question, Answer, ComplexSortedPerson, PluggableSearchPerson,
- PrePopulatedPostLargeSlug, AdminOrderedField, AdminOrderedModelMethod,
- AdminOrderedAdminMethod, AdminOrderedCallable, Report, Color2,
- UnorderedObject, MainPrepopulated, RelatedPrepopulated, UndeletableObject,
- UnchangeableObject, UserMessenger, Simple, Choice, ShortMessage, Telegram,
- FilteredManager, EmptyModelHidden, EmptyModelVisible, EmptyModelMixin,
- State, City, Restaurant, Worker, ParentWithDependentChildren,
- DependentChild, StumpJoke, FieldOverridePost, FunkyTag,
- ReferencedByParent, ChildOfReferer, ReferencedByInline,
- InlineReference, InlineReferer, Recipe, Ingredient, NotReferenced,
- ExplicitlyProvidedPK, ImplicitlyGeneratedPK,
+ Actor, AdminOrderedAdminMethod, AdminOrderedCallable, AdminOrderedField,
+ AdminOrderedModelMethod, Album, Answer, Article, BarAccount, Book,
+ Category, Chapter, ChapterXtra1, Child, ChildOfReferer, Choice, City,
+ Collector, Color, Color2, ComplexSortedPerson, CoverLetter, CustomArticle,
+ CyclicOne, CyclicTwo, DependentChild, DooHickey, EmptyModel,
+ EmptyModelHidden, EmptyModelMixin, EmptyModelVisible, ExplicitlyProvidedPK,
+ ExternalSubscriber, Fabric, FancyDoodad, FieldOverridePost,
+ FilteredManager, FooAccount, FoodDelivery, FunkyTag, Gadget, Gallery,
+ Grommet, ImplicitlyGeneratedPK, Ingredient, InlineReference, InlineReferer,
+ Inquisition, Language, Link, MainPrepopulated, ModelWithStringPrimaryKey,
+ NotReferenced, OldSubscriber, OtherStory, Paper, Parent,
+ ParentWithDependentChildren, Person, Persona, Picture, Pizza, Plot,
+ PlotDetails, PluggableSearchPerson, Podcast, Post, PrePopulatedPost,
+ PrePopulatedPostLargeSlug, PrePopulatedSubPost, Promo, Question, Recipe,
+ Recommendation, Recommender, ReferencedByInline, ReferencedByParent,
+ RelatedPrepopulated, Report, Reservation, Restaurant,
+ RowLevelChangePermissionModel, Section, ShortMessage, Simple, Sketch,
+ State, Story, StumpJoke, Subscriber, SuperVillain, Telegram, Thing,
+ Topping, UnchangeableObject, UndeletableObject, UnorderedObject,
+ UserMessenger, Villain, Vodcast, Whatsit, Widget, Worker, WorkHour,
)
@@ -969,8 +970,6 @@ site.register(ExplicitlyProvidedPK, GetFormsetsArgumentCheckingAdmin)
site.register(ImplicitlyGeneratedPK, GetFormsetsArgumentCheckingAdmin)
# Register core models we need in our tests
-from django.contrib.auth.models import User, Group
-from django.contrib.auth.admin import UserAdmin, GroupAdmin
site.register(User, UserAdmin)
site.register(Group, GroupAdmin)