diff options
author | Hans de Graaff <graaff@gentoo.org> | 2011-05-23 17:24:58 +0000 |
---|---|---|
committer | Hans de Graaff <graaff@gentoo.org> | 2011-05-23 17:24:58 +0000 |
commit | f4ea7cede0f6b5833313db60020e74a5bccfbdc4 (patch) | |
tree | 01df99251076233266a13d9d8c2ee2fc733fcac3 /dev-ruby/rspec-core | |
parent | x86 stable per bug 364863 (diff) | |
download | gentoo-2-f4ea7cede0f6b5833313db60020e74a5bccfbdc4.tar.gz gentoo-2-f4ea7cede0f6b5833313db60020e74a5bccfbdc4.tar.bz2 gentoo-2-f4ea7cede0f6b5833313db60020e74a5bccfbdc4.zip |
Add jruby support.
(Portage version: 2.1.9.42/cvs/Linux x86_64)
Diffstat (limited to 'dev-ruby/rspec-core')
-rw-r--r-- | dev-ruby/rspec-core/ChangeLog | 5 | ||||
-rw-r--r-- | dev-ruby/rspec-core/rspec-core-2.6.0.ebuild | 23 |
2 files changed, 23 insertions, 5 deletions
diff --git a/dev-ruby/rspec-core/ChangeLog b/dev-ruby/rspec-core/ChangeLog index 3c4c0344e2a6..dc3d456e41e9 100644 --- a/dev-ruby/rspec-core/ChangeLog +++ b/dev-ruby/rspec-core/ChangeLog @@ -1,6 +1,9 @@ # ChangeLog for dev-ruby/rspec-core # Copyright 1999-2011 Gentoo Foundation; Distributed under the GPL v2 -# $Header: /var/cvsroot/gentoo-x86/dev-ruby/rspec-core/ChangeLog,v 1.8 2011/05/13 10:26:40 graaff Exp $ +# $Header: /var/cvsroot/gentoo-x86/dev-ruby/rspec-core/ChangeLog,v 1.9 2011/05/23 17:24:58 graaff Exp $ + + 23 May 2011; Hans de Graaff <graaff@gentoo.org> rspec-core-2.6.0.ebuild: + Add jruby support. *rspec-core-2.6.0 (13 May 2011) diff --git a/dev-ruby/rspec-core/rspec-core-2.6.0.ebuild b/dev-ruby/rspec-core/rspec-core-2.6.0.ebuild index e680b3cdcb5d..26e1b33c6aca 100644 --- a/dev-ruby/rspec-core/rspec-core-2.6.0.ebuild +++ b/dev-ruby/rspec-core/rspec-core-2.6.0.ebuild @@ -1,9 +1,9 @@ # Copyright 1999-2011 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 -# $Header: /var/cvsroot/gentoo-x86/dev-ruby/rspec-core/rspec-core-2.6.0.ebuild,v 1.1 2011/05/13 10:26:40 graaff Exp $ +# $Header: /var/cvsroot/gentoo-x86/dev-ruby/rspec-core/rspec-core-2.6.0.ebuild,v 1.2 2011/05/23 17:24:58 graaff Exp $ EAPI=2 -USE_RUBY="ruby18 ree18 ruby19" +USE_RUBY="ruby18 ree18 ruby19 jruby" RUBY_FAKEGEM_TASK_TEST="none" RUBY_FAKEGEM_TASK_DOC="none" @@ -24,12 +24,13 @@ RDEPEND="${RDEPEND} !<dev-ruby/rspec-1.3.1-r1" ruby_add_bdepend "test? ( dev-ruby/syntax + >=dev-ruby/zentest-4.4.1 dev-ruby/rspec-expectations:2 dev-ruby/rspec-mocks:2 )" # >=dev-ruby/cucumber-0.5.3 -# >=dev-ruby/autotest-4.2.9 +# >=dev-ruby/autotest-4.2.9 -> zentest-4.4.1 # dev-ruby/aruba" all_ruby_prepare() { @@ -41,6 +42,11 @@ all_ruby_prepare() { # Also clean the /usr/lib/rubyee path (which is our own invention). sed -i -e 's#lib\\d\*\\/ruby\\/#lib\\d*\\/ruby(ee|)\\/#' lib/rspec/core/configuration.rb || die + + # Remove jruby-specific comparison documents since for us the normal + # version passes. + cp spec/rspec/core/formatters/html_formatted-1.8.7.html spec/rspec/core/formatters/html_formatted-1.8.7-jruby.html|| die + cp spec/rspec/core/formatters/text_mate_formatted-1.8.7.html spec/rspec/core/formatters/text_mate_formatted-1.8.7-jruby.html|| die } all_ruby_compile() { @@ -50,7 +56,16 @@ all_ruby_compile() { } each_ruby_test() { - PATH="${S}/bin:${PATH}" RUBYLIB="${S}/lib" ${RUBY} -S rake spec || die "Tests failed." + case ${RUBY} in + *jruby) + # Run jruby's tests with the installed rspec script since + # otherwise files can't be found for some unknown reason. + RUBYLIB=${S}/lib ${RUBY} -S rspec --color spec || die "Tests failed." + ;; + *) + PATH="${S}/bin:${PATH}" RUBYLIB="${S}/lib" ${RUBY} -S rake spec || die "Tests failed." + ;; + esac # There are features but it seems as if these only work against a # fully installed version. |