#5656: detect correct encoding of files when reporting coverage in trace.py, and ignore files in the temporary directory when reporting.
diff --git a/Lib/test/regrtest.py b/Lib/test/regrtest.py
index f970404..0408a02 100755
--- a/Lib/test/regrtest.py
+++ b/Lib/test/regrtest.py
@@ -404,8 +404,9 @@
print("Using random seed", random_seed)
random.shuffle(tests)
if trace:
- import trace
- tracer = trace.Trace(ignoredirs=[sys.prefix, sys.exec_prefix],
+ import trace, tempfile
+ tracer = trace.Trace(ignoredirs=[sys.prefix, sys.exec_prefix,
+ tempfile.gettempdir()],
trace=False, count=True)
test_times = []
support.verbose = verbose # Tell tests to be moderately quiet