Permalink
Browse files

bundler will use if parent bundler exists already, so empty it.

  • Loading branch information...
1 parent 949e710 commit 71fe3f498a9d9aeeab872a86c07cfffae95b53f4 @banyan banyan committed Apr 23, 2012
Showing with 9 additions and 5 deletions.
  1. +9 −5 Rakefile
View
@@ -43,13 +43,17 @@ task :default => :all_sorcery_specs
desc "Run all sorcery specs"
task :all_sorcery_specs do
+ # we need to be empty, otherwise bundler will use parent bundler.
+ env = {
+ 'BUNDLE_GEMFILE' => nil,
+ 'GEM_PATH' => nil,
+ 'GEM_HOME' => nil,
+ 'BUNDLE_BIN_PATH' => nil,
+ 'RUBYOPT' => nil
+ }
Dir['spec/**/Rakefile'].each do |rakefile|
directory_name = File.dirname(rakefile)
- sh <<-CMD
- cd #{directory_name}
- bundle
- bundle exec rake
- CMD
+ system(env, "cd #{directory_name} && pwd && bundle && bundle exec rake")
end
end

0 comments on commit 71fe3f4

Please sign in to comment.