mirror of
https://github.com/discourse/discourse.git
synced 2025-09-05 08:59:27 +08:00
DEV: Add a verbose option to ./bin/turbo_rspec
This commit is contained in:
parent
ed936bcb01
commit
d6aa92e98e
3 changed files with 53 additions and 16 deletions
|
@ -6,6 +6,7 @@ require 'optparse'
|
|||
|
||||
requires = []
|
||||
formatters = []
|
||||
verbose = false
|
||||
|
||||
OptionParser.new do |opts|
|
||||
opts.on("-r", "--require PATH", "Require a file.") do |filename|
|
||||
|
@ -28,6 +29,10 @@ OptionParser.new do |opts|
|
|||
end
|
||||
formatters.last[:outputs] << filename
|
||||
end
|
||||
|
||||
opts.on("-v", "--verbose", "More output") do
|
||||
verbose = true
|
||||
end
|
||||
end.parse!(ARGV)
|
||||
|
||||
requires.each { |f| require(f) }
|
||||
|
@ -45,4 +50,8 @@ formatters.each do |formatter|
|
|||
end
|
||||
end
|
||||
|
||||
TurboTests::Runner.run(formatters, ARGV.empty? ? ["spec"] : ARGV)
|
||||
TurboTests::Runner.run(
|
||||
formatters: formatters,
|
||||
files: ARGV.empty? ? ["spec"] : ARGV,
|
||||
verbose: verbose
|
||||
)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue