class ActiveSupport::Testing::ParallelizeExecutor

def build_parallel_executor

def build_parallel_executor
  case parallelize_with
  when :processes
    Testing::Parallelization.new(size)
  when :threads
    ActiveSupport::TestCase.lock_threads = false if defined?(ActiveSupport::TestCase.lock_threads)
    Minitest::Parallel::Executor.new(size)
  else
    raise ArgumentError, "#{parallelize_with} is not a supported parallelization executor."
  end
end