Merge pull request #4941 from blueyed/testdir-home
pytester: testdir: set $HOME to tmpdir
This commit is contained in:
@@ -469,6 +469,8 @@ class Testdir(object):
|
||||
os.environ["PYTEST_DEBUG_TEMPROOT"] = str(self.test_tmproot)
|
||||
os.environ.pop("TOX_ENV_DIR", None) # Ensure that it is not used for caching.
|
||||
os.environ.pop("PYTEST_ADDOPTS", None) # Do not use outer options.
|
||||
os.environ["HOME"] = str(self.tmpdir) # Do not load user config.
|
||||
os.environ["USERPROFILE"] = os.environ["HOME"]
|
||||
self.plugins = []
|
||||
self._cwd_snapshot = CwdSnapshot()
|
||||
self._sys_path_snapshot = SysPathsSnapshot()
|
||||
|
||||
Reference in New Issue
Block a user