[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
13/66: gnu: ruby-rspec-its: Enable tests.
From: |
guix-commits |
Subject: |
13/66: gnu: ruby-rspec-its: Enable tests. |
Date: |
Thu, 14 Feb 2019 16:38:33 -0500 (EST) |
cbaines pushed a commit to branch master
in repository guix.
commit 3306f02a74c0c3cb57f39701a04de4878c7d3777
Author: Christopher Baines <address@hidden>
Date: Sun Jan 27 12:14:26 2019 +0000
gnu: ruby-rspec-its: Enable tests.
Enable the tests, and also tweak the synopsis and description to hopefully
be
more descriptive.
* gnu/packages/ruby.scm (ruby-rspec-its)[source]: Change to GitHub, and add
patch.
[arguments]: Enabled tests, set the #:test-target to "spec", and add the
phases to tweak the Gemfile and rspec-its.gemspec.
[native-inputs]: Add bundler, ruby-cucumber and ruby-aruba.
[synopsis,description]: Make more explicit and descriptive.
---
gnu/packages/ruby.scm | 49 ++++++++++++++++++++++++++++++++++++++++++-------
1 file changed, 42 insertions(+), 7 deletions(-)
diff --git a/gnu/packages/ruby.scm b/gnu/packages/ruby.scm
index 9b3856f..906d9ff 100644
--- a/gnu/packages/ruby.scm
+++ b/gnu/packages/ruby.scm
@@ -412,20 +412,55 @@ outcomes of a code example.")
(version "1.2.0")
(source
(origin
- (method url-fetch)
- (uri (rubygems-uri "rspec-its" version))
+ (method git-fetch)
+ (uri (git-reference
+ (url "https://github.com/rspec/rspec-its.git")
+ (commit (string-append "v" version))))
+ (file-name (git-file-name name version))
(sha256
(base32
- "1pwphny5jawcm1hda3vs9pjv1cybaxy17dc1s75qd7drrvx697p3"))))
+ "190rz7v4q4wk80fzhr5hknvxx4vb2pywmqr8wc41w2blj9ylzi0f"))
+ (patches
+ (list
+ (origin (method url-fetch)
+ (uri (string-append
+ "https://github.com/rspec/rspec-its/commit/"
+ "bfaab439c7c879f5ef25552f41827891f6308373.patch"))
+ (file-name "ruby-rspec-its-fix-specs-for-ruby-2.4.patch")
+ (sha256
+ (base32
+
"0lnik0kvrpgkakvdb2fmzg22pdlraf6kiidr9sv6rnfyviiqwxgh")))))))
(build-system ruby-build-system)
(arguments
- `(#:tests? #f)) ; needs cucumber.
+ `(#:test-target "spec"
+ #:phases
+ (modify-phases %standard-phases
+ (add-after 'unpack 'dont-install-gems-from-gemfile
+ (lambda _
+ (substitute* "Gemfile"
+ (("rspec rspec-core rspec-expectations rspec-mocks
rspec-support")
+ ""))
+ #t))
+ (add-before 'build
'remove-unnecessary-dependency-versions-from-gemfile
+ (lambda _
+ (substitute* "rspec-its.gemspec"
+ (("rake.*") "rake'\n")
+ (("cucumber.*") "cucumber'\n")
+ (("bundler.*") "bundler'\n")
+ (("aruba.*") "aruba'\n"))
+ #t)))))
(propagated-inputs
`(("ruby-rspec-core" ,ruby-rspec-core)
("ruby-rspec-expectations" ,ruby-rspec-expectations)))
- (synopsis "RSpec extension gem for attribute matching")
- (description "@code{rspec-its} is an RSpec extension gem for attribute
-matching.")
+ (native-inputs
+ `(("bundler" ,bundler)
+ ("ruby-cucumber" ,ruby-cucumber)
+ ("ruby-aruba" ,ruby-aruba)))
+ (synopsis "RSpec extension that provides the @code{its} method")
+ (description
+ "RSpec::Its provides the its method as a short-hand to specify the
expected
+value of an attribute. For example, one can use @code{its(:size)\\{should
+eq(1)\\}}.")
(home-page "https://github.com/rspec/rspec-its")
(license license:expat)))
- branch master updated (17098a4 -> a3dbfbb), guix-commits, 2019/02/14
- 03/66: gnu: Add ruby-contracts., guix-commits, 2019/02/14
- 04/66: gnu: Add ruby-progressbar., guix-commits, 2019/02/14
- 01/66: gnu: ruby-safe-yaml: Add missing require 'time'., guix-commits, 2019/02/14
- 02/66: gnu: Add ruby-cucumber-wire., guix-commits, 2019/02/14
- 08/66: gnu: Add ruby-backports., guix-commits, 2019/02/14
- 06/66: gnu: Add ruby-cucumber-expressions., guix-commits, 2019/02/14
- 07/66: gnu: Add ruby-mspec., guix-commits, 2019/02/14
- 05/66: gnu: Add ruby-fuubar., guix-commits, 2019/02/14
- 14/66: gnu: Add ruby-powerpack., guix-commits, 2019/02/14
- 13/66: gnu: ruby-rspec-its: Enable tests.,
guix-commits <=
- 10/66: gnu: ruby-cucumber-core: Update to 3.2.1., guix-commits, 2019/02/14
- 09/66: gnu: Add ruby-cucumber-tag-expressions., guix-commits, 2019/02/14
- 11/66: gnu: ruby-gherkin: Update to 5.1.0., guix-commits, 2019/02/14
- 12/66: gnu: Add ruby-cucumber and ruby-aruba., guix-commits, 2019/02/14
- 20/66: gnu: Add ruby-rest-client., guix-commits, 2019/02/14
- 22/66: gnu: Add ruby-ast., guix-commits, 2019/02/14
- 33/66: gnu: ruby-addressable: Enable tests and update., guix-commits, 2019/02/14
- 18/66: gnu: Add ruby-crack., guix-commits, 2019/02/14
- 17/66: gnu: Add ruby-hashdiff., guix-commits, 2019/02/14
- 31/66: gnu: ruby-public-suffix: Enable tests., guix-commits, 2019/02/14