diff options
author | David Terry <me@xwvvvvwx.com> | 2019-10-27 14:09:57 +0100 |
---|---|---|
committer | David Terry <me@xwvvvvwx.com> | 2019-10-27 14:21:57 +0100 |
commit | 5cd5661378114f556f00a6cdc35e883ebf009aec (patch) | |
tree | 5faecd20536f514ef9e20f6c9685aa8fbfc0e718 /pkgs | |
parent | 4cd2cb43fb3a87f48c1e10bb65aee99d8f24cb9d (diff) | |
download | nixlib-5cd5661378114f556f00a6cdc35e883ebf009aec.tar nixlib-5cd5661378114f556f00a6cdc35e883ebf009aec.tar.gz nixlib-5cd5661378114f556f00a6cdc35e883ebf009aec.tar.bz2 nixlib-5cd5661378114f556f00a6cdc35e883ebf009aec.tar.lz nixlib-5cd5661378114f556f00a6cdc35e883ebf009aec.tar.xz nixlib-5cd5661378114f556f00a6cdc35e883ebf009aec.tar.zst nixlib-5cd5661378114f556f00a6cdc35e883ebf009aec.zip |
python3Packages.pytest4: deterministic bytecode
For reasons that are not clear to me, the pytest4 check phase produces a lot of non-deterministic bytecode files. This PR turns off bytecode generation and disables a test that force enables bytecode generation.
Diffstat (limited to 'pkgs')
-rw-r--r-- | pkgs/development/python-modules/pytest/4.nix | 14 |
1 files changed, 8 insertions, 6 deletions
diff --git a/pkgs/development/python-modules/pytest/4.nix b/pkgs/development/python-modules/pytest/4.nix index 7a43a2e2517b..3b3c7f663368 100644 --- a/pkgs/development/python-modules/pytest/4.nix +++ b/pkgs/development/python-modules/pytest/4.nix @@ -6,11 +6,6 @@ buildPythonPackage rec { version = "4.6.5"; pname = "pytest"; - preCheck = '' - # don't test bash builtins - rm testing/test_argcomplete.py - ''; - src = fetchPypi { inherit pname version; sha256 = "8fc39199bdda3d9d025d3b1f4eb99a192c20828030ea7c9a0d2840721de7d347"; @@ -25,7 +20,14 @@ buildPythonPackage rec { doCheck = !isPyPy; # https://github.com/pytest-dev/pytest/issues/3460 checkPhase = '' runHook preCheck - $out/bin/py.test -x testing/ -k "not test_collect_pyargs_with_testpaths" + + # don't test bash builtins + rm testing/test_argcomplete.py + + # determinism - this test writes non deterministic bytecode + rm -rf testing/test_assertrewrite.py + + PYTHONDONTWRITEBYTECODE=1 $out/bin/py.test -x testing/ -k "not test_collect_pyargs_with_testpaths" runHook postCheck ''; |