aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBen Woodcroft <donttrustben@gmail.com>2015-12-30 23:36:03 +1000
committerBen Woodcroft <donttrustben@gmail.com>2016-01-28 00:08:32 +1000
commit99fc5cd57710a0d74ade9bbf560fec4b2a259122 (patch)
tree77be83a164c6b6f166ad632a3ce03c65b1872e5d
parent39dc0eb50204f03e95a7a5636e7c28c8e5e0ae99 (diff)
downloadguix-99fc5cd57710a0d74ade9bbf560fec4b2a259122.tar
guix-99fc5cd57710a0d74ade9bbf560fec4b2a259122.tar.gz
gnu: Add ruby-minitest-pretty-diff.
* gnu/packages/ruby.scm (ruby-minitest-pretty-diff): New variable.
-rw-r--r--gnu/packages/ruby.scm35
1 files changed, 35 insertions, 0 deletions
diff --git a/gnu/packages/ruby.scm b/gnu/packages/ruby.scm
index 774653be24..7cc426660e 100644
--- a/gnu/packages/ruby.scm
+++ b/gnu/packages/ruby.scm
@@ -1546,6 +1546,41 @@ is to be run.")
(home-page "https://github.com/seattlerb/minitest-focus")
(license license:expat)))
+(define-public ruby-minitest-pretty-diff
+ ;; Use git reference because gem is out of date and does not contain testing
+ ;; script. There are no releases on GitHub.
+ (let ((commit "11f32e930f574225432f42e5e1ef6e7471efe572"))
+ (package
+ (name "ruby-minitest-pretty-diff")
+ (version (string-append "0.1-1." (string-take commit 8)))
+ (source (origin
+ (method git-fetch)
+ (uri (git-reference
+ (url "https://github.com/adammck/minitest-pretty_diff.git")
+ (commit commit)))
+ (file-name (string-append name "-" version "-checkout"))
+ (sha256
+ (base32
+ "13y5dhmcckhzd83gj1nfwh41iykbjcm2w7y4pr6j6rpqa5as122r"))))
+ (build-system ruby-build-system)
+ (arguments
+ `(#:phases
+ (modify-phases %standard-phases
+ (replace 'check
+ (lambda _
+ (zero? (system* "script/test")))))))
+ (native-inputs
+ `(("bundler" ,bundler)
+ ("ruby-turn" ,ruby-turn)))
+ (synopsis "Pretty-print hashes and arrays in MiniTest")
+ (description
+ "@code{minitest-pretty_diff} monkey-patches
+@code{MiniTest::Assertions#mu_pp} to pretty-print hashes and arrays before
+diffing them. This makes it easier to spot differences between nested
+structures when tests fail.")
+ (home-page "https://github.com/adammck/minitest-pretty_diff")
+ (license license:expat))))
+
(define-public ruby-daemons
(package
(name "ruby-daemons")