1{
2 lib,
3 buildPythonPackage,
4 fetchFromGitHub,
5 hatchling,
6 pytest,
7 pytestCheckHook,
8}:
9
10buildPythonPackage rec {
11 pname = "pytest-lazy-fixtures";
12 version = "1.3.2";
13 pyproject = true;
14
15 src = fetchFromGitHub {
16 owner = "dev-petrov";
17 repo = "pytest-lazy-fixtures";
18 tag = version;
19 hash = "sha256-h2Zm8Vbw3L9WeXaeFE/fJqiOgI3r+XnJUnnELDkmyaU=";
20 };
21
22 postPatch = ''
23 # Prevent double registration here and in the pyproject.toml entrypoint
24 # ValueError: Plugin already registered under a different name:
25 substituteInPlace tests/conftest.py \
26 --replace-fail '"pytest_lazy_fixtures.plugin",' ""
27 '';
28
29 build-system = [ hatchling ];
30
31 dependencies = [ pytest ];
32
33 nativeCheckInputs = [ pytestCheckHook ];
34
35 disabledTestPaths = [
36 # missing pytest-deadfixtures
37 "tests/test_deadfixtures_support.py"
38 ];
39
40 pythonImportsCheck = [ "pytest_lazy_fixtures" ];
41
42 meta = with lib; {
43 description = "Allows you to use fixtures in @pytest.mark.parametrize";
44 homepage = "https://github.com/dev-petrov/pytest-lazy-fixtures";
45 license = licenses.mit;
46 maintainers = [ ];
47 };
48}