diff options
| author | Nicolas Graves <ngraves@ngraves.fr> | 2024-04-20 16:11:00 +0200 |
|---|---|---|
| committer | Sharlatan Hellseher <sharlatanus@gmail.com> | 2025-09-25 09:35:33 +0100 |
| commit | e927a071cd25715deffc83faf5856d256870dc0e (patch) | |
| tree | 0c932785587735833057394bbb00d2c5aa4aa1c7 /gnu/packages/python-build.scm | |
| parent | 7b65bc85cd735999f361ee9d68310fe237cc2a3e (diff) | |
build-system/pyproject: Add python test-backend.
* guix/build/pyproject-build-system(check): Add python test-backend.
This will help in cases where a simple `python -m module args` call has
to be made instead of fully replacing the 'check phase, e.g. unittest
or django. This is never enabled unless #:test-backend 'python is set,
so it doesn't break anything.
As an example, the following snippet...
(arguments
(list #:phases #~(modify-phases %standard-phases
(replace 'check
(lambda* (#:key tests? #:allow-other-keys)
(when tests?
(invoke "python" "-m" "unittest"
"diff_match_patch.tests")))))))
...can be transformed like this:
(arguments
'(#:test-backend 'python
#:test-flags (list "-m" "unittest" "diff_match_patch.tests")))
Change-Id: I4919a3e01d64864e3c328609fbcce7df5b3dfe51
Signed-off-by: Sharlatan Hellseher <sharlatanus@gmail.com>
Diffstat (limited to 'gnu/packages/python-build.scm')
0 files changed, 0 insertions, 0 deletions
