diff options
author | jgart <jgart@dismail.de> | 2022-11-02 02:03:46 -0500 |
---|---|---|
committer | Christopher Baines <mail@cbaines.net> | 2022-11-05 11:44:08 +0100 |
commit | f91713e71b6bc1222c8f5b218dede3dc7e670a3c (patch) | |
tree | 43730cfe33dd87a698498984bd5d44fcff7d24b5 | |
parent | 83bfdb409787cb2737e68b093a319b247b7858e6 (diff) | |
download | guix-f91713e71b6bc1222c8f5b218dede3dc7e670a3c.tar.gz |
gnu: python-funcparserlib: Enable tests.
* gnu/packages/python-xyz.scm (python-funcparserlib): Enable tests. [origin]: Use GitHub since it includes the tests unlike PyPi. [build-system]: Use pyproject-build-system. [arguments]: Run tests. [native-inputs]: Add python-poetry-core. Signed-off-by: Christopher Baines <mail@cbaines.net>
-rw-r--r-- | gnu/packages/python-xyz.scm | 25 |
1 files changed, 18 insertions, 7 deletions
diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm index 684fe88740..5b619c5cfa 100644 --- a/gnu/packages/python-xyz.scm +++ b/gnu/packages/python-xyz.scm @@ -25348,14 +25348,25 @@ scripts to load entry points more quickly.") (name "python-funcparserlib") (version "1.0.0") (source - (origin - (method url-fetch) - (uri (pypi-uri "funcparserlib" version)) - (sha256 - (base32 "0swbqf53x7lfnczvi566s1g3nkf5mfrxz7sbpyymricz57a3vlvx")))) - (build-system python-build-system) + (origin + ;; Source tarball on PyPi lacks tests. + (method git-fetch) + (uri (git-reference + (url "https://github.com/vlasovskikh/funcparserlib") + (commit version))) + (file-name (git-file-name name version)) + (sha256 + (base32 "00pswdys5c4hpqpvfcy5zqv30gyjvjvagi12811jizw57hxrm1cs")))) + (build-system pyproject-build-system) (arguments - `(#:tests? #f)) ; no tests in PyPI and no setup.py in GitHub + '(#:phases + (modify-phases %standard-phases + (replace 'check + (lambda* (#:key tests? #:allow-other-keys) + (when tests? + (invoke "python" "-m" "unittest" "discover" "-v"))))))) + ;; ModuleNotFoundError: No module named 'poetry' + (native-inputs (list python-poetry-core)) (home-page "https://github.com/vlasovskikh/funcparserlib") (synopsis "Recursive descent parsing library based on functional combinators") |