2019-07-16 22:39:20 +01:00
|
|
|
{ lib
|
|
|
|
, buildPythonPackage
|
|
|
|
, fetchPypi
|
|
|
|
, fetchpatch
|
|
|
|
, isPy3k
|
|
|
|
, pytest
|
|
|
|
, mock
|
|
|
|
, setuptools_scm
|
|
|
|
}:
|
2018-02-12 11:37:41 +00:00
|
|
|
|
|
|
|
buildPythonPackage rec {
|
|
|
|
pname = "pytest-mock";
|
2019-12-19 19:31:20 +00:00
|
|
|
version = "1.13.0";
|
2019-02-14 07:37:27 +00:00
|
|
|
|
2018-02-12 11:37:41 +00:00
|
|
|
src = fetchPypi {
|
|
|
|
inherit pname version;
|
2019-12-19 19:31:20 +00:00
|
|
|
sha256 = "e24a911ec96773022ebcc7030059b57cd3480b56d4f5d19b7c370ec635e6aed5";
|
2018-02-12 11:37:41 +00:00
|
|
|
};
|
|
|
|
|
2019-02-14 07:37:27 +00:00
|
|
|
propagatedBuildInputs = lib.optional (!isPy3k) mock;
|
2019-07-16 22:39:20 +01:00
|
|
|
|
|
|
|
nativeBuildInputs = [
|
|
|
|
setuptools_scm
|
|
|
|
];
|
|
|
|
|
|
|
|
checkInputs = [
|
|
|
|
pytest
|
|
|
|
];
|
2018-02-12 11:37:41 +00:00
|
|
|
|
|
|
|
checkPhase = ''
|
2019-10-26 22:12:51 +01:00
|
|
|
pytest
|
2018-02-12 11:37:41 +00:00
|
|
|
'';
|
|
|
|
|
|
|
|
meta = with lib; {
|
|
|
|
description = "Thin-wrapper around the mock package for easier use with py.test.";
|
|
|
|
homepage = https://github.com/pytest-dev/pytest-mock;
|
|
|
|
license = licenses.mit;
|
|
|
|
maintainers = with maintainers; [ nand0p ];
|
|
|
|
};
|
|
|
|
}
|