Archived
1
0
Fork 0

gnu: python-pytest-toolbox: Honor #:tests? flag.

* gnu/packages/python-check.scm (python-pytest-toolbox)[arguments]:
Adjust custom 'check phase to honor the #:tests? flag.
This commit is contained in:
Efraim Flashner 2021-10-27 11:01:41 +03:00
parent c2179c27fe
commit d76e0a36f9
No known key found for this signature in database
GPG key ID: 41AAE7DCCA3D8351

View file

@ -1129,12 +1129,13 @@ service processes for your tests with pytest.")
'(#:phases '(#:phases
(modify-phases %standard-phases (modify-phases %standard-phases
(replace 'check (replace 'check
(lambda* (#:key inputs outputs #:allow-other-keys) (lambda* (#:key tests? inputs outputs #:allow-other-keys)
(substitute* "setup.cfg" (when tests?
((".*timeout.*") "")) (substitute* "setup.cfg"
;; Make the installed plugin discoverable by Pytest. ((".*timeout.*") ""))
(add-installed-pythonpath inputs outputs) ;; Make the installed plugin discoverable by Pytest.
(invoke "pytest" "-vv")))))) (add-installed-pythonpath inputs outputs)
(invoke "pytest" "-vv")))))))
(native-inputs (native-inputs
`(("python-pydantic" ,python-pydantic) `(("python-pydantic" ,python-pydantic)
("python-pytest" ,python-pytest) ("python-pytest" ,python-pytest)