File tree Expand file tree Collapse file tree
pkgs/development/python-modules/pytest Expand file tree Collapse file tree Original file line number Diff line number Diff line change 55, fetchPypi
66, writeText
77
8- # build
8+ # build-system
99, setuptools
1010, setuptools-scm
1111
12- # propagates
12+ # dependencies
1313, attrs
1414, exceptiongroup
1515, iniconfig
1616, packaging
1717, pluggy
18- , py
1918, tomli
19+
20+ # optional-dependencies
21+ , argcomplete
22+ , hypothesis
23+ , mock
24+ , nose
25+ , pygments
26+ , requests
27+ , xmlschema
2028} :
2129
2230buildPythonPackage rec {
@@ -40,16 +48,28 @@ buildPythonPackage rec {
4048 ] ;
4149
4250 propagatedBuildInputs = [
43- attrs
4451 iniconfig
4552 packaging
4653 pluggy
47- py
48- tomli
4954 ] ++ lib . optionals ( pythonOlder "3.11" ) [
5055 exceptiongroup
56+ tomli
5157 ] ;
5258
59+ passthru . optional-dependencies = {
60+ testing = [
61+ argcomplete
62+ attrs
63+ hypothesis
64+ mock
65+ nose
66+ pygments
67+ requests
68+ setuptools
69+ xmlschema
70+ ] ;
71+ } ;
72+
5373 postInstall = ''
5474 mkdir $testout
5575 cp -R testing $testout/testing
Original file line number Diff line number Diff line change 11{ buildPythonPackage
22, isPyPy
33, pytest
4- , hypothesis
5- , pygments
64} :
75
86buildPythonPackage rec {
97 pname = "pytest-tests" ;
108 inherit ( pytest ) version ;
9+ format = "other" ;
1110
1211 src = pytest . testout ;
1312
1413 dontBuild = true ;
1514 dontInstall = true ;
1615
17- nativeCheckInputs = [
18- hypothesis
19- pygments
20- ] ;
16+ nativeCheckInputs = pytest . optional-dependencies . testing ;
2117
2218 doCheck = ! isPyPy ; # https://github.com/pytest-dev/pytest/issues/3460
2319
2420 # Ignored file https://github.com/pytest-dev/pytest/pull/5605#issuecomment-522243929
2521 # test_missing_required_plugins will emit deprecation warning which is treated as error
2622 checkPhase = ''
2723 runHook preCheck
28- ${ pytest . out } /bin/py.test -x testing/ \
24+ ${ pytest . out } /bin/pytest -x testing/ \
2925 --ignore=testing/test_junitxml.py \
3026 --ignore=testing/test_argcomplete.py \
3127 -k "not test_collect_pyargs_with_testpaths and not test_missing_required_plugins"
You can’t perform that action at this time.
0 commit comments