pythonPackages.pytest: pathlib2 is only required for python<3.6

This commit is contained in:
Mario Rodas 2018-10-17 21:40:16 -05:00 committed by Frederik Rietdijk
parent 5df3a4d9b9
commit 5143e30361

View file

@ -1,4 +1,4 @@
{ stdenv, buildPythonPackage, fetchPypi, attrs, hypothesis, py
{ stdenv, buildPythonPackage, pythonOlder, fetchPypi, attrs, hypothesis, py
, setuptools_scm, setuptools, six, pluggy, funcsigs, isPy3k, more-itertools
, atomicwrites, mock, writeText, pathlib2
}:
@ -19,7 +19,8 @@ buildPythonPackage rec {
checkInputs = [ hypothesis mock ];
buildInputs = [ setuptools_scm ];
propagatedBuildInputs = [ attrs py setuptools six pluggy more-itertools atomicwrites]
++ stdenv.lib.optionals (!isPy3k) [ funcsigs pathlib2 ];
++ stdenv.lib.optionals (!isPy3k) [ funcsigs ]
++ stdenv.lib.optionals (pythonOlder "3.6") [ pathlib2 ];
checkPhase = ''
runHook preCheck