gnu: Add python-jaraco-context.

* gnu/packages/python-xyz.scm (python-jaraco-context): New variable.
This commit is contained in:
Maxim Cournoyer 2022-04-06 00:12:13 -04:00
parent f761974b12
commit 26d92095d6
No known key found for this signature in database
GPG key ID: 1260E46482E63562

View file

@ -8616,6 +8616,35 @@ (define-public python-jaraco-context-bootstrap
procedures.") procedures.")
(license license:expat)))) (license license:expat))))
(define-public python-jaraco-context
(package/inherit python-jaraco-context-bootstrap
(name "python-jaraco-context")
(arguments
(substitute-keyword-arguments
(package-arguments python-jaraco-context-bootstrap)
((#:tests? _ #f)
#t)
((#:phases phases #~%standard-phases)
#~(modify-phases #$phases
(replace 'check
(lambda* (#:key tests? #:allow-other-keys)
(when tests?
;; Do not test the myproject.toml build as it tries to pull
;; dependencies from the Internet.
(invoke "pytest" "-vv" "-k" "not project"))))))))
(native-inputs
(modify-inputs
(package-native-inputs python-jaraco-context-bootstrap)
(append python-pytest
python-pytest-black
python-pytest-checkdocs
python-pytest-cov
python-pytest-enabler-bootstrap ;OK since not propagated
python-pytest-flake8
python-pytest-mypy)))
(properties (alist-delete 'hidden? (package-properties
python-jaraco-context-bootstrap)))))
;;; Variant used to break a cycle with python-pytest-enabler. ;;; Variant used to break a cycle with python-pytest-enabler.
(define-public python-jaraco-functools-bootstrap (define-public python-jaraco-functools-bootstrap
(hidden-package (hidden-package