未验证 提交 f666fb58 编写于 作者: K Kasper Timm Hansen 提交者: GitHub

Merge pull request #33267 from utilum/railties_testopts

Fix assignment of TESTOPTS in railties test task
......@@ -31,6 +31,8 @@ namespace :test do
failing_files = []
dirs = (ENV["TEST_DIR"] || ENV["TEST_DIRS"] || "**").split(",")
test_options = ENV["TESTOPTS"].to_s.split(/[\s]+/)
test_files = dirs.map { |dir| "test/#{dir}/*_test.rb" }
Dir[*test_files].each do |file|
next true if file.start_with?("test/fixtures/")
......@@ -46,7 +48,7 @@ namespace :test do
# We could run these in parallel, but pretty much all of the
# railties tests already run in parallel, so ¯\_(⊙︿⊙)_/¯
Process.waitpid fork {
ARGV.clear.push ENV["TESTOPTS"]
ARGV.clear.concat test_options
Rake.application = nil
load file
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册