Method: Minitest::TestTask#make_test_cmd
- Defined in:
- lib/minitest/test_task.rb
#make_test_cmd(globs = test_globs) ⇒ Object
Generate the test command-line.
253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 |
# File 'lib/minitest/test_task.rb', line 253 def make_test_cmd globs = test_globs tests = [] tests.concat Dir[*globs].sort.shuffle # TODO: SEED -> srand first? tests.map! { |f| %(require "#{f}") } runner = [] runner << test_prelude if test_prelude runner << framework runner.concat tests runner = runner.join "; " args = [] args << "-I#{libs.join(File::PATH_SEPARATOR)}" unless libs.empty? args << "-w" if warning args << '-e' args << "'#{runner}'" args << '--' args << extra_args.map(&:shellescape) args.join " " end |