You are an expert in writing code in many different languages. Your goal is to perform code completion for the following code, keeping in mind the rest of the code and the file meta data.
    Metadata details:
    filename: test_cli.rb
    path of file: ./repos/nanoc/nanoc/test/orig_cli
    
    the code of the file until where you have to start completion: # frozen_string_literal: true

require 'helper'

class Nanoc::OrigCLITest < Nanoc::TestCase
  COMMAND_CODE = <<~EOS
    usage       '_test [options]'
    summary     'meh'
    description 'longer meh'

    run do |opts, args, cmd|
      File.open('_test.out', 'w') { |io| io.write('It works!') }
    
  def test_load_custom_commands_broken
    Nanoc::CLI.run %w[create_site foo]

    FileUtils.cd('foo') do
      # Create command
      FileUtils.mkdir_p('commands')
      File.write('commands/_test.rb', 'raise "meh"')

      begin
        orig_stderr = $stderr
        tmp_stderr = StringIO.new
        $stderr = tmp_stderr

        # Run command
        Nanoc::CLI::ErrorHandler.disable
        assert_raises RuntimeError do
          Nanoc::CLI.run %w[_test]
        end
        Nanoc::CLI::ErrorHandler.enable
        assert_raises SystemExit do
          Nanoc::CLI.run %w[_test]
        end
      ensure
        $stderr = orig_stderr
      end

      # Check error output
      assert_match(/commands\/_test.rb/, tmp_stderr.string)
    end