2023-01-20 10:41:00 +00:00
|
|
|
{ lib
|
|
|
|
, isPyPy
|
|
|
|
, buildPythonPackage
|
2024-05-15 15:35:15 +00:00
|
|
|
, pytest-fixture-config
|
|
|
|
, fetchpatch
|
2023-01-20 10:41:00 +00:00
|
|
|
|
2024-05-15 15:35:15 +00:00
|
|
|
# build-time
|
|
|
|
, setuptools
|
|
|
|
, setuptools-git
|
2023-01-20 10:41:00 +00:00
|
|
|
|
|
|
|
# runtime
|
2024-05-15 15:35:15 +00:00
|
|
|
, pytest
|
2023-01-20 10:41:00 +00:00
|
|
|
, mock
|
|
|
|
, path
|
|
|
|
, execnet
|
|
|
|
, termcolor
|
|
|
|
, six
|
|
|
|
|
|
|
|
# tests
|
|
|
|
, pytestCheckHook
|
|
|
|
}:
|
2020-04-24 23:36:52 +00:00
|
|
|
|
|
|
|
buildPythonPackage rec {
|
|
|
|
pname = "pytest-shutil";
|
2024-05-15 15:35:15 +00:00
|
|
|
inherit (pytest-fixture-config) version src;
|
|
|
|
pyproject = true;
|
2020-04-24 23:36:52 +00:00
|
|
|
|
2024-05-15 15:35:15 +00:00
|
|
|
sourceRoot = "${src.name}/pytest-shutil";
|
2020-04-24 23:36:52 +00:00
|
|
|
|
2024-05-15 15:35:15 +00:00
|
|
|
# imp was removed in Python 3.12
|
|
|
|
patches = [
|
|
|
|
(fetchpatch {
|
|
|
|
name = "stop-using-imp.patch";
|
|
|
|
url = "https://build.opensuse.org/public/source/openSUSE:Factory/python-pytest-shutil/stop-using-imp.patch?rev=10";
|
|
|
|
hash = "sha256-L8tXoQ9q8o6aP3TpJY/sUVVbUd/ebw0h6de6dBj1WNY=";
|
|
|
|
stripLen = 1;
|
|
|
|
})
|
2023-01-20 10:41:00 +00:00
|
|
|
];
|
2020-04-24 23:36:52 +00:00
|
|
|
|
2024-05-15 15:35:15 +00:00
|
|
|
build-system = [
|
|
|
|
setuptools
|
2023-01-20 10:41:00 +00:00
|
|
|
setuptools-git
|
2024-05-15 15:35:15 +00:00
|
|
|
];
|
|
|
|
|
|
|
|
buildInputs = [ pytest ];
|
|
|
|
|
|
|
|
dependencies = [
|
2023-01-20 10:41:00 +00:00
|
|
|
mock
|
|
|
|
path
|
|
|
|
execnet
|
|
|
|
termcolor
|
|
|
|
six
|
|
|
|
];
|
|
|
|
|
2023-02-02 18:25:31 +00:00
|
|
|
nativeCheckInputs = [
|
2023-01-20 10:41:00 +00:00
|
|
|
pytestCheckHook
|
|
|
|
];
|
|
|
|
|
|
|
|
disabledTests = [
|
|
|
|
"test_pretty_formatter"
|
|
|
|
] ++ lib.optionals isPyPy [
|
|
|
|
"test_run"
|
|
|
|
"test_run_integration"
|
|
|
|
];
|
2020-04-24 23:36:52 +00:00
|
|
|
|
2021-01-15 22:18:51 +00:00
|
|
|
meta = with lib; {
|
2020-04-24 23:36:52 +00:00
|
|
|
description = "A goodie-bag of unix shell and environment tools for py.test";
|
|
|
|
homepage = "https://github.com/manahl/pytest-plugins";
|
|
|
|
maintainers = with maintainers; [ ryansydnor ];
|
|
|
|
license = licenses.mit;
|
|
|
|
};
|
|
|
|
}
|