GNU bug report logs - #62196
[PATCH 000/182] Add FPM, update Rails and other Ruby additions/updates

Previous Next

Package: guix-patches;

Reported by: Maxim Cournoyer <maxim.cournoyer <at> gmail.com>

Date: Wed, 15 Mar 2023 03:01:02 UTC

Severity: normal

Tags: patch

Done: Maxim Cournoyer <maxim.cournoyer <at> gmail.com>

Bug is archived. No further changes may be made.

Full log


Message #35 received at 62196 <at> debbugs.gnu.org (full text, mbox):

From: Maxim Cournoyer <maxim.cournoyer <at> gmail.com>
To: 62196 <at> debbugs.gnu.org
Cc: Maxim Cournoyer <maxim.cournoyer <at> gmail.com>
Subject: [PATCH 032/223] gnu: ruby-standard: Enable test suite.
Date: Mon, 20 Mar 2023 13:13:24 -0400
* gnu/packages/ruby.scm (ruby-standard) [arguments]: Delete #:tests? argument.
Delete relax-version-requiremens phase.  Add set-HOME and
delete-problematic-tests phases.
[propagated-inputs]: Add ruby-language-server-protocol.
---
 gnu/packages/ruby.scm | 29 ++++++++++++++++++++---------
 1 file changed, 20 insertions(+), 9 deletions(-)

diff --git a/gnu/packages/ruby.scm b/gnu/packages/ruby.scm
index 265dd6e50a..b06bdbcb6b 100644
--- a/gnu/packages/ruby.scm
+++ b/gnu/packages/ruby.scm
@@ -1816,17 +1816,28 @@ (define-public ruby-standard
          "0c0lsrvdl224s8166xrk9ibm19wbzn5l9s27cm7bjn0jr81j6agk"))))
     (build-system ruby-build-system)
     (arguments
-     ;; TODO: the tests are currently broken due to using a different Rubocop
-     ;; version.
-     `(#:tests? #f
-       #:phases
+     `(#:phases
        (modify-phases %standard-phases
-         (add-after 'unpack 'relax-version-requiremens
+         (add-after 'unpack 'set-HOME
            (lambda _
-             (delete-file "Gemfile")
-             (delete-file "Gemfile.lock"))))))
-    (native-inputs (list ruby-gimme ruby-pry ruby-simplecov))
-    (propagated-inputs (list ruby-rubocop ruby-rubocop-performance))
+             ;; Some tests fail otherwise.
+             (setenv "HOME" "/tmp")))
+         (add-after 'unpack 'delete-problematic-tests
+           ;; These tests fail for unknown reasons (see:
+           ;; https://github.com/testdouble/standard/issues/532).
+           (lambda _
+             (for-each
+              delete-file
+              '("test/standard_test.rb"
+                "test/standard/cop/block_single_line_braces_test.rb")))))))
+    (native-inputs
+     (list ruby-gimme
+           ruby-pry
+           ruby-simplecov))
+    (propagated-inputs
+     (list ruby-language-server-protocol
+           ruby-rubocop
+           ruby-rubocop-performance))
     (synopsis "Ruby Style Guide, with linter & automatic code fixer")
     (description "Standard is a port of StandardJS.  Like StandardJS, it aims
 to save time in the following ways:
-- 
2.39.1





This bug report was last modified 2 years and 109 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.