summaryrefslogtreecommitdiff
path: root/gnu/packages/python-xyz.scm
diff options
context:
space:
mode:
authorVinicius Monego <monego@posteo.net>2021-11-05 01:58:36 +0000
committerLudovic Courtès <ludo@gnu.org>2021-12-12 00:27:55 +0100
commit8bb6c7425d6edf532f2db1be5d09d26af6431e89 (patch)
tree54539781100ab62a15bef51b37755e7ab8560d9a /gnu/packages/python-xyz.scm
parent7a34e56dc811d75c2d4665d68e0f646abeaf28d9 (diff)
gnu: python-moto: Honor #:tests? flag.
* gnu/packages/python-xyz.scm (python-moto)[arguments]: Adjust custom 'check phase to honor the #:tests? flag. Signed-off-by: Ludovic Courtès <ludo@gnu.org>
Diffstat (limited to 'gnu/packages/python-xyz.scm')
-rw-r--r--gnu/packages/python-xyz.scm29
1 files changed, 15 insertions, 14 deletions
diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm
index 6ed2407958..b3a350aca4 100644
--- a/gnu/packages/python-xyz.scm
+++ b/gnu/packages/python-xyz.scm
@@ -13374,20 +13374,21 @@ text.")
(substitute* (find-files "tests" "\\.py$")
(("#!/bin/bash") (string-append "#!" bash-exec))))))
(replace 'check
- (lambda* (#:key inputs outputs #:allow-other-keys)
- (add-installed-pythonpath inputs outputs)
- (invoke "pytest" "-vv" "-m" "not network" "-k"
- (string-append
- ;; These tests require Docker.
- "not test_terminate_job"
- " and not test_invoke_function_from_sqs_exception"
- " and not test_rotate_secret_lambda_invocations"
- ;; These tests also require the network.
- " and not test_put_record_batch_http_destination"
- " and not test_put_record_http_destination"
- " and not test_dependencies"
- " and not test_cancel_running_job"
- " and not test_container_overrides")))))))
+ (lambda* (#:key inputs outputs tests? #:allow-other-keys)
+ (when tests?
+ (add-installed-pythonpath inputs outputs)
+ (invoke "pytest" "-vv" "-m" "not network" "-k"
+ (string-append
+ ;; These tests require Docker.
+ "not test_terminate_job"
+ " and not test_invoke_function_from_sqs_exception"
+ " and not test_rotate_secret_lambda_invocations"
+ ;; These tests also require the network.
+ " and not test_put_record_batch_http_destination"
+ " and not test_put_record_http_destination"
+ " and not test_dependencies"
+ " and not test_cancel_running_job"
+ " and not test_container_overrides"))))))))
(native-inputs
`(("python-flask" ,python-flask)
("python-flask-cors" ,python-flask-cors)