fix rake tasks for testing
This commit is contained in:
parent
09ff7aa90a
commit
883dfa618e
12
Rakefile
12
Rakefile
|
@ -1,11 +1,8 @@
|
||||||
require 'bundler'
|
require 'bundler'
|
||||||
Bundler::GemHelper.install_tasks
|
Bundler::GemHelper.install_tasks
|
||||||
|
require 'rspec/core/rake_task'
|
||||||
|
|
||||||
desc "Run on this Ruby"
|
RSpec::Core::RakeTask.new(:spec)
|
||||||
task :spec do
|
|
||||||
system %{rspec spec}
|
|
||||||
exit $?.exitstatus
|
|
||||||
end
|
|
||||||
|
|
||||||
namespace :spec do
|
namespace :spec do
|
||||||
desc "Run on three Rubies"
|
desc "Run on three Rubies"
|
||||||
|
@ -15,8 +12,9 @@ namespace :spec do
|
||||||
fail = false
|
fail = false
|
||||||
%w{1.8.7 1.9.2 ree}.each do |version|
|
%w{1.8.7 1.9.2 ree}.each do |version|
|
||||||
puts "Switching to #{version}"
|
puts "Switching to #{version}"
|
||||||
system %{rvm #{version}}
|
Bundler.with_clean_env do
|
||||||
system %{rspec spec}
|
system %{bash -c 'source ~/.rvm/scripts/rvm && rvm #{version} && bundle && bundle exec rake spec'}
|
||||||
|
end
|
||||||
if $?.exitstatus != 0
|
if $?.exitstatus != 0
|
||||||
fail = true
|
fail = true
|
||||||
break
|
break
|
||||||
|
|
Loading…
Reference in New Issue