Deprecate the dircache module for 3.0.
diff --git a/Lib/test/test_dircache.py b/Lib/test/test_dircache.py
index 68f6fc2..276c52a 100644
--- a/Lib/test/test_dircache.py
+++ b/Lib/test/test_dircache.py
@@ -4,8 +4,9 @@
"""
import unittest
-from test.test_support import run_unittest, TESTFN
-import dircache, os, time, sys, tempfile
+from test.test_support import run_unittest, TESTFN, import_module
+dircache = import_module('dircache', deprecated=True)
+import os, time, sys, tempfile
class DircacheTests(unittest.TestCase):
@@ -66,7 +67,10 @@
def test_main():
- run_unittest(DircacheTests)
+ try:
+ run_unittest(DircacheTests)
+ finally:
+ dircache.reset()
if __name__ == "__main__":