summaryrefslogtreecommitdiff
path: root/tests/app_loading
diff options
context:
space:
mode:
authorMariusz Felisiak <felisiak.mariusz@gmail.com>2023-12-31 10:01:31 +0100
committerGitHub <noreply@github.com>2023-12-31 10:01:31 +0100
commitd88ec42bd0a37340c8477a6f20bf26e58bd84735 (patch)
treeabd9422f7fb34a19579a74515ce84d9f472cd226 /tests/app_loading
parent81ccf92f154c6d9eac3e30bac0aa67574d0ace15 (diff)
Used addCleanup() in tests where appropriate.
Diffstat (limited to 'tests/app_loading')
-rw-r--r--tests/app_loading/tests.py4
1 files changed, 1 insertions, 3 deletions
diff --git a/tests/app_loading/tests.py b/tests/app_loading/tests.py
index 1499115386..d8a837c2f6 100644
--- a/tests/app_loading/tests.py
+++ b/tests/app_loading/tests.py
@@ -8,9 +8,7 @@ from django.test.utils import extend_sys_path
class EggLoadingTest(SimpleTestCase):
def setUp(self):
self.egg_dir = "%s/eggs" % os.path.dirname(__file__)
-
- def tearDown(self):
- apps.clear_cache()
+ self.addCleanup(apps.clear_cache)
def test_egg1(self):
"""Models module can be loaded from an app in an egg"""