diff mbox series

[bug#62196,194/223] gnu: ruby-shoulda: Honor #:tests?.

Message ID 20230320172349.12752-93-maxim.cournoyer@gmail.com
State New
Headers show
Series None | expand

Commit Message

Maxim Cournoyer March 20, 2023, 5:23 p.m. UTC
* gnu/packages/ruby.scm (ruby-shoulda)
[arguments]: Honor #:tests? in check phase.
---

 gnu/packages/ruby.scm | 8 +++++---
 1 file changed, 5 insertions(+), 3 deletions(-)
diff mbox series

Patch

diff --git a/gnu/packages/ruby.scm b/gnu/packages/ruby.scm
index ad4ca4b926..c359a9364f 100644
--- a/gnu/packages/ruby.scm
+++ b/gnu/packages/ruby.scm
@@ -10152,9 +10152,11 @@  (define-public ruby-shoulda
      `(#:phases
        (modify-phases %standard-phases
          (replace 'check
-           ;; Don't run tests to avoid circular dependence with rails.  Instead
-           ;; just import the library to test.
-           (lambda _ (invoke "ruby" "-Ilib" "-r" "shoulda")))
+           (lambda* (#:key tests? #:allow-other-keys)
+             (when tests?
+               ;; Don't run tests to avoid circular dependence with rails.
+               ;; Instead just import the library to test.
+               (invoke "ruby" "-Ilib" "-r" "shoulda"))))
          (add-after 'extract-gemspec 'relax-requirements
            (lambda _
              (substitute* "shoulda.gemspec"