Fix resource warnings thanks to PDM (#68)
* Run Azure tests in python development mode
* Fix identified resource leaks
Markus Gerstel authored 3 years ago
GitHub committed 3 years ago
4 | 4 |
2.3.0 (????-??-??)
|
5 | 5 |
------------------
|
6 | 6 |
* Python 3.6+ only, support for Python 3.5 has been dropped
|
|
7 |
* Fix a file descriptor leak on subprocess execution
|
7 | 8 |
|
8 | 9 |
2.2.0 (2020-09-07)
|
9 | 10 |
------------------
|
55 | 55 |
def test_path_object_resolution(tmp_path):
|
56 | 56 |
sentinel_value = b"sentinel"
|
57 | 57 |
tmp_path.joinpath("tempfile").write_bytes(sentinel_value)
|
58 | |
tmp_path.joinpath("reader.py").write_text("print(open('tempfile').read())")
|
|
58 |
tmp_path.joinpath("reader.py").write_text(
|
|
59 |
"with open('tempfile') as fh:\n print(fh.read())"
|
|
60 |
)
|
59 | 61 |
assert "LEAK_DETECTOR" not in os.environ
|
60 | 62 |
result = procrunner.run(
|
61 | 63 |
[sys.executable, tmp_path / "reader.py"],
|
13 | 13 |
pytest-azurepipelines
|
14 | 14 |
pytest-cov
|
15 | 15 |
-r{toxinidir}/requirements_dev.txt
|
|
16 |
setenv =
|
|
17 |
PYTHONDEVMODE = 1
|
16 | 18 |
commands =
|
17 | 19 |
pytest -ra --basetemp={envtmpdir} --cov=procrunner --cov-report=html --cov-report=xml --cov-branch
|
18 | 20 |
|