gnu: python-plotly: Allow test phase to be skipped.

* gnu/packages/graph.scm (python-plotly)[arguments]: Wrap custom 'check
phase tests with test with tests? keyword.
This commit is contained in:
Efraim Flashner 2021-03-04 14:47:42 +02:00
parent 3e5d811387
commit e9096ef105
No known key found for this signature in database
GPG Key ID: 41AAE7DCCA3D8351

@ -170,12 +170,14 @@ lines.")
(chdir "packages/python/plotly") (chdir "packages/python/plotly")
#t)) #t))
(replace 'check (replace 'check
(lambda _ (lambda* (#:key tests? #:allow-other-keys)
(when tests?
(invoke "pytest" "-x" "plotly/tests/test_core") (invoke "pytest" "-x" "plotly/tests/test_core")
(invoke "pytest" "-x" "plotly/tests/test_io") (invoke "pytest" "-x" "plotly/tests/test_io")
;; FIXME: Add optional dependencies and enable their tests. ;; FIXME: Add optional dependencies and enable their tests.
;; (invoke "pytest" "-x" "plotly/tests/test_optional") ;; (invoke "pytest" "-x" "plotly/tests/test_optional")
(invoke "pytest" "_plotly_utils/tests"))) (invoke "pytest" "_plotly_utils/tests"))
#t))
(add-before 'reset-gzip-timestamps 'make-files-writable (add-before 'reset-gzip-timestamps 'make-files-writable
(lambda* (#:key outputs #:allow-other-keys) (lambda* (#:key outputs #:allow-other-keys)
(let ((out (assoc-ref outputs "out"))) (let ((out (assoc-ref outputs "out")))