1 { lib, buildPythonPackage, pythonOlder, fetchPypi, isPy3k, isPyPy
22 buildPythonPackage rec {
29 inherit pname version;
30 sha256 = "1n67lk8iwlsmfdm8663k8l7isllg1xd3n9p1yla7885szhdk6ybr";
33 checkInputs = [ hypothesis pygments ];
34 nativeBuildInputs = [ setuptools_scm ];
35 propagatedBuildInputs = [
46 ] ++ lib.optionals (pythonOlder "3.6") [ pathlib2 ];
48 doCheck = !isPyPy; # https://github.com/pytest-dev/pytest/issues/3460
51 # don't test bash builtins
52 rm testing/test_argcomplete.py
55 # Ignored file https://github.com/pytest-dev/pytest/pull/5605#issuecomment-522243929
58 $out/bin/py.test -x testing/ -k "not test_collect_pyargs_with_testpaths" --ignore=testing/test_junitxml.py
62 # Remove .pytest_cache when using py.test in a Nix build
63 setupHook = writeText "pytest-hook" ''
65 find $out -name .pytest_cache -type d -exec rm -rf {} +
67 preDistPhases+=" pytestcachePhase"
70 pythonImportsCheck = [
75 homepage = "https://docs.pytest.org";
76 description = "Framework for writing tests";
77 maintainers = with maintainers; [ domenkozar lovek323 madjar lsix ];
78 license = licenses.mit;