Merge pull request #11268 from bluetech/conftest-load

config: split `_getconftestmodules` and `_loadconftestmodules`
This commit is contained in:
Ran Benita
2023-08-08 14:44:29 +03:00
committed by GitHub
5 changed files with 50 additions and 84 deletions

View File

@@ -2103,9 +2103,7 @@ class TestAutouseManagement:
reprec = pytester.inline_run("-v", "-s", "--confcutdir", pytester.path)
reprec.assertoutcome(passed=8)
config = reprec.getcalls("pytest_unconfigure")[0].config
values = config.pluginmanager._getconftestmodules(
p, importmode="prepend", rootpath=pytester.path
)[0].values
values = config.pluginmanager._getconftestmodules(p)[0].values
assert values == ["fin_a1", "fin_a2", "fin_b1", "fin_b2"] * 2
def test_scope_ordering(self, pytester: Pytester) -> None: