2020-06-15 15:56:04 +00:00
|
|
|
{ lib
|
2020-04-24 23:36:52 +00:00
|
|
|
, buildPythonPackage
|
|
|
|
, fetchPypi
|
2021-02-19 19:06:45 +00:00
|
|
|
, fetchpatch
|
2020-06-15 15:56:04 +00:00
|
|
|
, six, pyyaml, mock
|
|
|
|
, pytestCheckHook
|
|
|
|
, enum34
|
|
|
|
, isPy3k
|
2020-04-24 23:36:52 +00:00
|
|
|
}:
|
|
|
|
|
|
|
|
buildPythonPackage rec {
|
|
|
|
pname = "ddt";
|
2020-06-15 15:56:04 +00:00
|
|
|
version = "1.4.1";
|
2020-04-24 23:36:52 +00:00
|
|
|
|
|
|
|
src = fetchPypi {
|
|
|
|
inherit pname version;
|
2020-06-15 15:56:04 +00:00
|
|
|
sha256 = "0595e70d074e5777771a45709e99e9d215552fb1076443a25fad6b23d8bf38da";
|
2020-04-24 23:36:52 +00:00
|
|
|
};
|
|
|
|
|
2021-02-19 19:06:45 +00:00
|
|
|
patches = [
|
|
|
|
# fix tests with recent PyYAML, https://github.com/datadriventests/ddt/pull/96
|
|
|
|
(fetchpatch {
|
|
|
|
url = "https://github.com/datadriventests/ddt/commit/97f0a2315736e50f1b34a015447cd751da66ecb6.patch";
|
|
|
|
sha256 = "1g7l5h7m7s4yqfxlygrg7nnhb9xhz1drjld64ssi3fbsmn7klf0a";
|
|
|
|
})
|
|
|
|
];
|
|
|
|
|
2020-06-15 15:56:04 +00:00
|
|
|
checkInputs = [ six pyyaml mock pytestCheckHook ];
|
2020-04-24 23:36:52 +00:00
|
|
|
|
2020-06-15 15:56:04 +00:00
|
|
|
propagatedBuildInputs = lib.optionals (!isPy3k) [
|
|
|
|
enum34
|
|
|
|
];
|
2020-04-24 23:36:52 +00:00
|
|
|
|
2020-06-15 15:56:04 +00:00
|
|
|
meta = with lib; {
|
2020-04-24 23:36:52 +00:00
|
|
|
description = "Data-Driven/Decorated Tests, a library to multiply test cases";
|
|
|
|
homepage = "https://github.com/txels/ddt";
|
|
|
|
license = licenses.mit;
|
|
|
|
};
|
|
|
|
|
|
|
|
}
|