mirror of
https://git.in.rschanz.org/ryan77627/guix.git
synced 2024-12-26 06:18:07 -05:00
gnu: python-jupyter-client: Enable tests.
* gnu/packages/python-xyz.scm (python-jupyter-client) [arguments]: Enable tests. Run pytest during 'check. [native-inputs]: Add missing test inputs.
This commit is contained in:
parent
f371e53aaa
commit
7914515cd3
1 changed files with 23 additions and 13 deletions
|
@ -7437,19 +7437,22 @@ (define-public python-jupyter-client
|
||||||
(base32
|
(base32
|
||||||
"10p7fcgvv9hvz9zical9wk68ks5ssak2ykbzx65wm1k1hk8a3g64"))))
|
"10p7fcgvv9hvz9zical9wk68ks5ssak2ykbzx65wm1k1hk8a3g64"))))
|
||||||
(build-system python-build-system)
|
(build-system python-build-system)
|
||||||
;; Tests fail because of missing native python kernel which I assume is
|
|
||||||
;; provided by the ipython package, which we cannot use because it would
|
|
||||||
;; cause a dependency cycle.
|
|
||||||
(arguments
|
(arguments
|
||||||
`(#:tests? #f
|
`(#:phases
|
||||||
#:phases (modify-phases %standard-phases
|
(modify-phases %standard-phases
|
||||||
(add-after 'unpack 'set-tool-file-names
|
(add-after 'unpack 'set-tool-file-names
|
||||||
(lambda* (#:key inputs #:allow-other-keys)
|
(lambda* (#:key inputs #:allow-other-keys)
|
||||||
(let ((iproute (assoc-ref inputs "iproute")))
|
(let ((iproute (assoc-ref inputs "iproute")))
|
||||||
(substitute* "jupyter_client/localinterfaces.py"
|
(substitute* "jupyter_client/localinterfaces.py"
|
||||||
(("'ip'")
|
(("'ip'")
|
||||||
(string-append "'" iproute "/sbin/ip'")))
|
(string-append "'" iproute "/sbin/ip'")))
|
||||||
#t))))))
|
#t)))
|
||||||
|
(replace 'check
|
||||||
|
(lambda* (#:key tests? #:allow-other-keys)
|
||||||
|
(when tests?
|
||||||
|
;; Some tests try to write to $HOME.
|
||||||
|
(setenv "HOME" "/tmp")
|
||||||
|
(invoke "pytest" "-vv")))))))
|
||||||
(inputs
|
(inputs
|
||||||
`(("iproute" ,iproute)))
|
`(("iproute" ,iproute)))
|
||||||
(propagated-inputs
|
(propagated-inputs
|
||||||
|
@ -7459,7 +7462,14 @@ (define-public python-jupyter-client
|
||||||
("python-tornado" ,python-tornado-6)
|
("python-tornado" ,python-tornado-6)
|
||||||
("python-traitlets" ,python-traitlets)))
|
("python-traitlets" ,python-traitlets)))
|
||||||
(native-inputs
|
(native-inputs
|
||||||
`(("python-pytest" ,python-pytest)))
|
`(("python-pytest" ,python-pytest)
|
||||||
|
("python-pytest-asyncio" ,python-pytest-asyncio)
|
||||||
|
("python-pytest-timeout" ,python-pytest-timeout)
|
||||||
|
("python-async-generator" ,python-async-generator)
|
||||||
|
("python-mock" ,python-mock)
|
||||||
|
("python-msgpack" ,python-msgpack)
|
||||||
|
("python-ipython" ,python-ipython)
|
||||||
|
("python-ipykernel" ,python-ipykernel-bootstrap)))
|
||||||
(home-page "https://jupyter.org/")
|
(home-page "https://jupyter.org/")
|
||||||
(synopsis "Jupyter protocol implementation and client libraries")
|
(synopsis "Jupyter protocol implementation and client libraries")
|
||||||
(description
|
(description
|
||||||
|
|
Loading…
Reference in a new issue