Skip to content

Commit 72d7977

Browse files
committed
TESTOPTS
1 parent 0fefe64 commit 72d7977

File tree

2 files changed

+15
-0
lines changed

2 files changed

+15
-0
lines changed

Rakefile

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -238,6 +238,8 @@ task :stdlib_test => :compile do
238238
test_files.shuffle!
239239
end
240240

241+
ENV["TESTOPTS"] ||= "--verbose"
242+
241243
sh "#{ruby} -Ilib #{bin}/test_runner.rb #{test_files.join(' ')}"
242244
# TODO: Ractor tests need to be run in a separate process
243245
sh "#{ruby} -Ilib #{bin}/test_runner.rb test/stdlib/CGI-escape_test.rb"

bin/test_runner.rb

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,8 @@
1818
/cannot load such file -- #{lib}/
1919
end
2020

21+
require 'test/unit'
22+
2123
ARGV.each do |arg|
2224
begin
2325
load arg
@@ -29,3 +31,14 @@
2931
end
3032
end
3133
end
34+
35+
args = []
36+
37+
unless ENV["TESTOPTS"].nil?
38+
require "shellwords"
39+
args.concat Shellwords.shellsplit(ENV["TESTOPTS"])
40+
end
41+
42+
exit Test::Unit::AutoRunner.run(false, nil, args)
43+
44+

0 commit comments

Comments
 (0)