summary refs log tree commit diff
path: root/gnu
diff options
context:
space:
mode:
authorMaxim Cournoyer <maxim.cournoyer@gmail.com>2023-03-18 00:03:40 -0400
committerMaxim Cournoyer <maxim.cournoyer@gmail.com>2023-03-28 22:22:49 -0400
commit464aa1def741d87e0b42f4a5dd68278d2a18ba50 (patch)
treeba76ddbfa7dfdf49de5da68616a153e030226196 /gnu
parent2be4b3c59bd2658c192a6d103a3639cacdb6853b (diff)
downloadguix-464aa1def741d87e0b42f4a5dd68278d2a18ba50.tar.gz
gnu: Add ruby-spy.
* gnu/packages/ruby.scm (ruby-spy): New variable.
Diffstat (limited to 'gnu')
-rw-r--r--gnu/packages/ruby.scm32
1 files changed, 32 insertions, 0 deletions
diff --git a/gnu/packages/ruby.scm b/gnu/packages/ruby.scm
index 5db81fbba7..a06ae4f5c1 100644
--- a/gnu/packages/ruby.scm
+++ b/gnu/packages/ruby.scm
@@ -13848,6 +13848,38 @@ development kit for Ruby.")
     (home-page "https://github.com/mtsmfm/language_server-protocol-ruby")
     (license license:expat)))
 
+(define-public ruby-spy
+  (package
+    (name "ruby-spy")
+    (version "1.0.5")
+    (source (origin
+              (method url-fetch)
+              (uri (rubygems-uri "spy" version))
+              (sha256
+               (base32
+                "0g2mma8q17m26k5s864ndlvvqllhcivwg2wdigjvb7z06iw17gds"))))
+    (build-system ruby-build-system)
+    (arguments
+     (list #:phases #~(modify-phases %standard-phases
+                        (add-after 'extract-gemspec 'relax-requirements
+                          (lambda _
+                            (substitute* "Gemfile"
+                              ((".*redcarpet.*") "")
+                              ((".*yard.*") "")))))))
+    (native-inputs
+     (list ruby-coveralls
+           ruby-minitest-reporters
+           ruby-pry
+           ruby-pry-byebug
+           ruby-rspec-core
+           ruby-rspec-expectations))
+    (synopsis "Mocking library for Ruby")
+    (description "Spy is a mocking library.  By default, it will raise an
+error if you attempt to stub a method that doesn't exist or call the stubbed
+method with the wrong arity.")
+    (home-page "https://github.com/ryanong/spy")
+    (license license:expat)))
+
 (define-public ruby-subprocess
   (package
     (name "ruby-subprocess")