summaryrefslogtreecommitdiffstats
path: root/Lib/test/test_py_compile.py
diff options
context:
space:
mode:
Diffstat (limited to 'Lib/test/test_py_compile.py')
-rw-r--r--Lib/test/test_py_compile.py5
1 files changed, 3 insertions, 2 deletions
diff --git a/Lib/test/test_py_compile.py b/Lib/test/test_py_compile.py
index d4a68c9..11b579c 100644
--- a/Lib/test/test_py_compile.py
+++ b/Lib/test/test_py_compile.py
@@ -9,13 +9,14 @@ import tempfile
import unittest
from test import support
+from test.support import os_helper
def without_source_date_epoch(fxn):
"""Runs function with SOURCE_DATE_EPOCH unset."""
@functools.wraps(fxn)
def wrapper(*args, **kwargs):
- with support.EnvironmentVarGuard() as env:
+ with os_helper.EnvironmentVarGuard() as env:
env.unset('SOURCE_DATE_EPOCH')
return fxn(*args, **kwargs)
return wrapper
@@ -25,7 +26,7 @@ def with_source_date_epoch(fxn):
"""Runs function with SOURCE_DATE_EPOCH set."""
@functools.wraps(fxn)
def wrapper(*args, **kwargs):
- with support.EnvironmentVarGuard() as env:
+ with os_helper.EnvironmentVarGuard() as env:
env['SOURCE_DATE_EPOCH'] = '123456789'
return fxn(*args, **kwargs)
return wrapper