Skip to content

Commit

Permalink
tests: better isolate test_venv_fail
Browse files Browse the repository at this point in the history
  • Loading branch information
tjni committed Oct 15, 2022
1 parent 03f93d5 commit aaaf4f8
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions tests/test_main.py
Expand Up @@ -415,6 +415,8 @@ def test_venv_fail(monkeypatch, package_test_flit, tmp_dir, capsys):
monkeypatch.setattr(venv.EnvBuilder, 'create', raise_called_process_err)
monkeypatch.setenv('NO_COLOR', '')

importlib.reload(build.__main__) # reload module to set _STYLES

with pytest.raises(SystemExit):
build.__main__.main([package_test_flit, '-o', tmp_dir])

Expand Down

0 comments on commit aaaf4f8

Please sign in to comment.