Skip to content

Commit da55c69

Browse files
committed
test_provision: new test for explicit .tox env override
1 parent 1672e2f commit da55c69

File tree

1 file changed

+9
-0
lines changed

1 file changed

+9
-0
lines changed

tests/test_provision.py

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -203,3 +203,12 @@ def test_provision_plugin_runner(tox_project: ToxProjectCreator, tmp_path: Path,
203203
f" [requires (has)]: demo-pkg-inline"
204204
)
205205
assert prov_msg in result_first.out
206+
207+
208+
@pytest.mark.integration()
209+
def test_provision_plugin_runner_in_provision(tox_project: ToxProjectCreator, tmp_path: Path) -> None:
210+
"""Ensure that provision environment can be explicitly configured."""
211+
log = tmp_path / "out.log"
212+
proj = tox_project({"tox.ini": "[tox]\nrequires=somepkg123xyz\n[testenv:.tox]\nrunner=example"})
213+
with pytest.raises(KeyError, match="example"):
214+
proj.run("r", "-e", "py", "--result-json", str(log))

0 commit comments

Comments
 (0)