diff options
author | Chris Lamb <chris@chris-lamb.co.uk> | 2020-07-20 13:04:07 +0200 |
---|---|---|
committer | Chris Lamb <chris@chris-lamb.co.uk> | 2020-07-20 13:04:07 +0200 |
commit | 9c1a0647b51c12a830d847b2a37b9c8008264d9b (patch) | |
tree | 9d104f22b3c32c95ad1aa701e3134958798e8f87 /logilab/common/pytest.py | |
parent | a5208bbd68a108c9bbed6f20ab1e801a004b982f (diff) | |
download | logilab-common-9c1a0647b51c12a830d847b2a37b9c8008264d9b.tar.gz |
Make the build reproducible
Diffstat (limited to 'logilab/common/pytest.py')
-rw-r--r-- | logilab/common/pytest.py | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/logilab/common/pytest.py b/logilab/common/pytest.py index b7f2e83..3b60ecf 100644 --- a/logilab/common/pytest.py +++ b/logilab/common/pytest.py @@ -209,8 +209,10 @@ def load_pytest_conf(path, parser): return namespace.get("CustomPyTester", PyTester) -def project_root(parser, projdir=os.getcwd()): +def project_root(parser, projdir=None): """try to find project's root and add it to sys.path""" + if projdir is None: + projdir = os.getcwd() previousdir = curdir = osp.abspath(projdir) testercls = PyTester conf_file_path = osp.join(curdir, CONF_FILE) |