mirror of
https://github.com/python/cpython.git
synced 2025-11-25 04:34:37 +00:00
Deprecate the dircache module for 3.0.
This commit is contained in:
parent
10f5db6424
commit
0aa6e1b8fb
5 changed files with 19 additions and 5 deletions
|
|
@ -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 @@ class DircacheTests(unittest.TestCase):
|
|||
|
||||
|
||||
def test_main():
|
||||
run_unittest(DircacheTests)
|
||||
try:
|
||||
run_unittest(DircacheTests)
|
||||
finally:
|
||||
dircache.reset()
|
||||
|
||||
|
||||
if __name__ == "__main__":
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue