diff options
author | John Kehayias <john.kehayias@protonmail.com> | 2023-11-05 17:17:02 -0500 |
---|---|---|
committer | John Kehayias <john.kehayias@protonmail.com> | 2023-11-05 22:09:48 -0500 |
commit | d70f2b788e56545f93dc24238d2617e20fde7460 (patch) | |
tree | 6e55321e3c9bedc384fd46a261392ae2980a1e4e /gnu/packages/curl.scm | |
parent | 00442f15d46cd9d5d02499827946d23426aad0ba (diff) | |
download | guix-d70f2b788e56545f93dc24238d2617e20fde7460.tar.gz |
gnu: curl: Run tests in parallel.
* gnu/packages/curl.scm (curl)[arguments]: Respect PARALLEL-TESTS? in check phase, by setting TFLAGS (curl's test flags). Change-Id: I54dfe32b757824fd3d2b89d10b88315c7e8b8d2a
Diffstat (limited to 'gnu/packages/curl.scm')
-rw-r--r-- | gnu/packages/curl.scm | 17 |
1 files changed, 12 insertions, 5 deletions
diff --git a/gnu/packages/curl.scm b/gnu/packages/curl.scm index ea1c2c9924..346bfc4e61 100644 --- a/gnu/packages/curl.scm +++ b/gnu/packages/curl.scm @@ -118,15 +118,22 @@ (rename-file (string-append #$output "/share/man/man3") (string-append #$output:doc "/share/man/man3")))) (replace 'check - (lambda* (#:key tests? make-flags #:allow-other-keys) + (lambda* (#:key tests? parallel-tests? make-flags #:allow-other-keys) (substitute* "tests/runtests.pl" (("/bin/sh") (which "sh"))) (when tests? - (let ((arguments `("-C" "tests" "test" - ,@(if #$(system-hurd?) + (let* ((job-count (string-append + "-j" + (if parallel-tests? + (number->string (parallel-job-count)) + "1"))) + (arguments `("-C" "tests" "test" + ,@make-flags + ,(if #$(system-hurd?) ;; protocol FAIL - (list make-flags "TFLAGS=~1474") - make-flags)))) + (string-append "TFLAGS=\"~1474 " + job-count "\"") + (string-append "TFLAGS=" job-count))))) ;; The top-level "make check" does "make -C tests quiet-test", which ;; is too quiet. Use the "test" target instead, which is more ;; verbose. |