2023-01-11 07:51:40 +00:00
|
|
|
{ lib
|
|
|
|
, buildPythonPackage
|
|
|
|
, fetchPypi
|
2023-10-09 19:29:22 +00:00
|
|
|
, flit-core
|
2023-01-11 07:51:40 +00:00
|
|
|
, pytestCheckHook
|
|
|
|
, numpy
|
|
|
|
, decopatch
|
|
|
|
, more-itertools
|
|
|
|
, nestedtext
|
|
|
|
, pyyaml
|
|
|
|
, tidyexc
|
|
|
|
, toml
|
|
|
|
}:
|
|
|
|
|
|
|
|
buildPythonPackage rec {
|
|
|
|
pname = "parametrize-from-file";
|
2023-11-16 04:20:00 +00:00
|
|
|
version = "0.18.0";
|
2023-10-09 19:29:22 +00:00
|
|
|
format = "pyproject";
|
2023-01-11 07:51:40 +00:00
|
|
|
|
|
|
|
src = fetchPypi {
|
|
|
|
inherit version;
|
|
|
|
pname = "parametrize_from_file";
|
2023-11-16 04:20:00 +00:00
|
|
|
hash = "sha256-mYE8J7XWlvCS2H3kt0bB8dyPHFDqmW8NiH9UCrNccAU=";
|
2023-01-11 07:51:40 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
# patch out coveralls since it doesn't provide us value
|
|
|
|
preBuild = ''
|
|
|
|
sed -i '/coveralls/d' ./pyproject.toml
|
2023-01-20 10:41:00 +00:00
|
|
|
|
|
|
|
substituteInPlace pyproject.toml \
|
|
|
|
--replace "more_itertools~=8.10" "more_itertools"
|
2023-01-11 07:51:40 +00:00
|
|
|
'';
|
|
|
|
|
2023-10-09 19:29:22 +00:00
|
|
|
nativeBuildInputs = [
|
|
|
|
flit-core
|
|
|
|
];
|
|
|
|
|
2023-02-02 18:25:31 +00:00
|
|
|
nativeCheckInputs = [
|
2023-01-11 07:51:40 +00:00
|
|
|
numpy
|
|
|
|
pytestCheckHook
|
|
|
|
];
|
2023-01-20 10:41:00 +00:00
|
|
|
|
2023-01-11 07:51:40 +00:00
|
|
|
propagatedBuildInputs = [
|
|
|
|
decopatch
|
|
|
|
more-itertools
|
|
|
|
nestedtext
|
|
|
|
pyyaml
|
|
|
|
tidyexc
|
|
|
|
toml
|
|
|
|
];
|
|
|
|
|
2023-03-08 16:32:21 +00:00
|
|
|
pythonImportsCheck = [
|
|
|
|
"parametrize_from_file"
|
|
|
|
];
|
|
|
|
|
|
|
|
disabledTests = [
|
|
|
|
# https://github.com/kalekundert/parametrize_from_file/issues/19
|
|
|
|
"test_load_suite_params_err"
|
|
|
|
];
|
2023-01-20 10:41:00 +00:00
|
|
|
|
2023-01-11 07:51:40 +00:00
|
|
|
meta = with lib; {
|
|
|
|
description = "Read unit test parameters from config files";
|
|
|
|
homepage = "https://github.com/kalekundert/parametrize_from_file";
|
|
|
|
changelog = "https://github.com/kalekundert/parametrize_from_file/blob/v${version}/CHANGELOG.md";
|
|
|
|
license = licenses.mit;
|
|
|
|
maintainers = with maintainers; [ jpetrucciani ];
|
|
|
|
};
|
|
|
|
}
|