Use config_invocation_dir for startdirs (#5151)
Use config_invocation_dir for startdirs
This commit is contained in:
commit
3f5622c577
|
@ -435,7 +435,7 @@ class Session(nodes.FSCollector):
|
||||||
self.shouldfail = False
|
self.shouldfail = False
|
||||||
self.trace = config.trace.root.get("collection")
|
self.trace = config.trace.root.get("collection")
|
||||||
self._norecursepatterns = config.getini("norecursedirs")
|
self._norecursepatterns = config.getini("norecursedirs")
|
||||||
self.startdir = py.path.local()
|
self.startdir = config.invocation_dir
|
||||||
self._initialpaths = frozenset()
|
self._initialpaths = frozenset()
|
||||||
# Keep track of any collected nodes in here, so we don't duplicate fixtures
|
# Keep track of any collected nodes in here, so we don't duplicate fixtures
|
||||||
self._node_cache = {}
|
self._node_cache = {}
|
||||||
|
|
|
@ -234,7 +234,7 @@ class TerminalReporter(object):
|
||||||
self._showfspath = None
|
self._showfspath = None
|
||||||
|
|
||||||
self.stats = {}
|
self.stats = {}
|
||||||
self.startdir = py.path.local()
|
self.startdir = config.invocation_dir
|
||||||
if file is None:
|
if file is None:
|
||||||
file = sys.stdout
|
file = sys.stdout
|
||||||
self._tw = _pytest.config.create_terminal_writer(config, file)
|
self._tw = _pytest.config.create_terminal_writer(config, file)
|
||||||
|
|
Loading…
Reference in New Issue