class Minitest::TestTask

def make_test_cmd globs = test_globs

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