[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
12/17: gnu: Add ruby-shoulda-matchers.
From: |
Ben Woodcroft |
Subject: |
12/17: gnu: Add ruby-shoulda-matchers. |
Date: |
Wed, 27 Jan 2016 14:12:27 +0000 |
benwoodcroft pushed a commit to branch master
in repository guix.
commit e4fea00896244635c9e89770315e365879a99105
Author: Ben Woodcroft <address@hidden>
Date: Thu Dec 31 09:12:59 2015 +1000
gnu: Add ruby-shoulda-matchers.
* gnu/packages/ruby.scm (ruby-shoulda-matchers): New variable.
---
gnu/packages/ruby.scm | 38 ++++++++++++++++++++++++++++++++++++++
1 files changed, 38 insertions(+), 0 deletions(-)
diff --git a/gnu/packages/ruby.scm b/gnu/packages/ruby.scm
index 0dc3561..d876f57 100644
--- a/gnu/packages/ruby.scm
+++ b/gnu/packages/ruby.scm
@@ -3219,6 +3219,44 @@ names.")
(home-page "https://github.com/thoughtbot/shoulda-context")
(license license:expat)))
+(define-public ruby-shoulda-matchers
+ (package
+ (name "ruby-shoulda-matchers")
+ (version "3.0.1")
+ (source
+ (origin
+ (method url-fetch)
+ (uri (rubygems-uri "shoulda-matchers" version))
+ (sha256
+ (base32
+ "1agabvb8i39mjrp3kb78nvhl41xk1i258hdwdlj0fm8nj9yzn1jb"))))
+ (build-system ruby-build-system)
+ (arguments
+ `(#:phases
+ (modify-phases %standard-phases
+ (add-before 'build 'fix-import
+ (lambda _
+ ;; A presumed bug reported upstream at
+ ;; https://github.com/thoughtbot/shoulda-matchers/pull/871
+ (substitute* (string-append "lib/shoulda/matchers/active_model/"
+ "validate_inclusion_of_matcher.rb")
+ (("^require 'bigdecimal'")
+ "require 'bigdecimal'; require 'date'"))))
+ (replace 'check
+ (lambda _
+ ;; Do not run tests to avoid circular dependence with rails.
Instead
+ ;; just import the library to test.
+ (zero? (system* "ruby" "-Ilib" "-r" "shoulda-matchers")))))))
+ (propagated-inputs
+ `(("ruby-activesupport" ,ruby-activesupport)))
+ (synopsis "Collection of testing matchers extracted from Shoulda")
+ (description
+ "Shoulda Matchers provides RSpec- and Minitest-compatible one-liners that
+test common Rails functionality. These tests would otherwise be much longer,
+more complex, and error-prone.")
+ (home-page "https://github.com/thoughtbot/shoulda-matchers")
+ (license license:expat)))
+
(define-public ruby-ansi
(package
(name "ruby-ansi")
- branch master updated (f66842d -> d114cee), Ben Woodcroft, 2016/01/27
- 02/17: gnu: Add ruby-minitest-focus., Ben Woodcroft, 2016/01/27
- 06/17: gnu: Add ruby-minitest-rg., Ben Woodcroft, 2016/01/27
- 04/17: gnu: Add ruby-minitest-moar., Ben Woodcroft, 2016/01/27
- 12/17: gnu: Add ruby-shoulda-matchers.,
Ben Woodcroft <=
- 05/17: gnu: Add ruby-minitest-bonus-assertions., Ben Woodcroft, 2016/01/27
- 14/17: gnu: Add ruby-shoulda., Ben Woodcroft, 2016/01/27
- 16/17: gnu: Add ruby-domain-name., Ben Woodcroft, 2016/01/27
- 17/17: gnu: Add ruby-http-cookie., Ben Woodcroft, 2016/01/27
- 13/17: gnu: Add ruby-shoulda-matchers-2., Ben Woodcroft, 2016/01/27
- 10/17: gnu: Add ruby-sqlite3., Ben Woodcroft, 2016/01/27
- 07/17: gnu: Add ruby-mime-types-data., Ben Woodcroft, 2016/01/27
- 08/17: gnu: Add ruby-fivemat., Ben Woodcroft, 2016/01/27
- 09/17: gnu: Add ruby-mime-types., Ben Woodcroft, 2016/01/27
- 15/17: gnu: Add ruby-unf., Ben Woodcroft, 2016/01/27