Don't create DSession in collect-only mode
This commit is contained in:
@@ -91,6 +91,7 @@ def pytest_addhooks(pluginmanager):
|
||||
|
||||
@pytest.mark.trylast
|
||||
def pytest_configure(config):
|
||||
if not config.getvalue("collectonly"):
|
||||
if config.getoption("dist") != "no":
|
||||
from xdist.dsession import DSession
|
||||
session = DSession(config)
|
||||
|
||||
Reference in New Issue
Block a user