diff options
Diffstat (limited to 'tests/contenttypes_tests')
| -rw-r--r-- | tests/contenttypes_tests/test_management.py | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/tests/contenttypes_tests/test_management.py b/tests/contenttypes_tests/test_management.py index 65842aa09e..57d3757abe 100644 --- a/tests/contenttypes_tests/test_management.py +++ b/tests/contenttypes_tests/test_management.py @@ -20,9 +20,12 @@ class RemoveStaleContentTypesTests(TestCase): 'django.contrib.contenttypes', ] + @classmethod + def setUpTestData(cls): + cls.before_count = ContentType.objects.count() + cls.content_type = ContentType.objects.create(app_label='contenttypes_tests', model='Fake') + def setUp(self): - self.before_count = ContentType.objects.count() - self.content_type = ContentType.objects.create(app_label='contenttypes_tests', model='Fake') self.app_config = apps.get_app_config('contenttypes_tests') def test_interactive_true_with_dependent_objects(self): |
