0
0
mirror of https://github.com/python/cpython.git synced 2024-11-28 08:20:55 +01:00
cpython/Lib/test/test_support.py
1992-01-27 17:00:37 +00:00

23 lines
424 B
Python

# Python test set -- supporting definitions.
TestFailed = 'test_support -- test failed' # Exception
def unload(name):
import sys
try:
del sys.modules[name]
except KeyError:
pass
def forget(modname):
unload(modname)
import sys, os
for dirname in sys.path:
try:
os.unlink(os.path.join(dirname, modname + '.pyc'))
except os.error:
pass
TESTFN = '@test' # Filename used for testing
from os import unlink