提交 f52832de 编写于 作者: A Arun Agrawal

grab executable from rubygems

As done here d7fc97d3
上级 310fc2b8
......@@ -14,9 +14,8 @@ Rake::TestTask.new { |t|
namespace :test do
task :isolated do
ruby = File.join(*RbConfig::CONFIG.values_at('bindir', 'RUBY_INSTALL_NAME'))
Dir.glob("test/**/*_test.rb").all? do |file|
sh(ruby, '-w', '-Ilib:test', file)
sh(Gem.ruby, '-w', '-Ilib:test', file)
end or raise "Failures"
end
end
......
......@@ -20,9 +20,8 @@ end
namespace :test do
task :isolated do
ruby = File.join(*RbConfig::CONFIG.values_at('bindir', 'RUBY_INSTALL_NAME'))
test_files.all? do |file|
sh(ruby, '-w', '-Ilib:test', file)
sh(Gem.ruby, '-w', '-Ilib:test', file)
end or raise "Failures"
end
end
......
......@@ -18,9 +18,8 @@ end
namespace :test do
task :isolated do
ruby = File.join(*RbConfig::CONFIG.values_at('bindir', 'RUBY_INSTALL_NAME'))
Dir.glob("test/{active_record,template}/**/*_test.rb").all? do |file|
sh(ruby, '-w', '-Ilib:test', file)
sh(Gem.ruby, '-w', '-Ilib:test', file)
end or raise "Failures"
end
......
......@@ -13,9 +13,8 @@ end
namespace :test do
task :isolated do
ruby = File.join(*RbConfig::CONFIG.values_at('bindir', 'RUBY_INSTALL_NAME'))
Dir.glob("#{dir}/test/**/*_test.rb").all? do |file|
sh(ruby, '-w', "-I#{dir}/lib", "-I#{dir}/test", file)
sh(Gem.ruby, '-w', "-I#{dir}/lib", "-I#{dir}/test", file)
end or raise "Failures"
end
end
......
......@@ -58,11 +58,10 @@ end
task "isolated_test_#{adapter}" do
adapter_short = adapter == 'db2' ? adapter : adapter[/^[a-z0-9]+/]
puts [adapter, adapter_short].inspect
ruby = File.join(*RbConfig::CONFIG.values_at('bindir', 'RUBY_INSTALL_NAME'))
(Dir["test/cases/**/*_test.rb"].reject {
|x| x =~ /\/adapters\//
} + Dir["test/cases/adapters/#{adapter_short}/**/*_test.rb"]).all? do |file|
sh(ruby, '-w' ,"-Itest", file)
sh(Gem.ruby, '-w' ,"-Itest", file)
end or raise "Failures"
end
......
......@@ -12,9 +12,8 @@ end
namespace :test do
task :isolated do
ruby = File.join(*RbConfig::CONFIG.values_at('bindir', 'RUBY_INSTALL_NAME'))
Dir.glob("test/**/*_test.rb").all? do |file|
sh(ruby, '-w', '-Ilib:test', file)
sh(Gem.ruby, '-w', '-Ilib:test', file)
end or raise "Failures"
end
end
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册