<commit_before>module MiniTest
  # Runner for individual MiniTest tests.
  # 
  # You *should not* create instances of this class directly. Instances of
  # {SuiteRunner} will create these and send them to the reporters.
  # 
  # Based upon <NAME> of Seattle.rb's MiniTest (MIT License).
  # 
  # @see https://github.com/seattlerb/minitest MiniTest
  class TestRunner
    attr_reader :suite, :test, :assertions, :result, :exception
    
    def initialize(suite, test)
      @suite = suite
      @test = test
      @assertions = 0
    end
    
    def run
      suite_instance = suite.new(test)
      @result, @exception = fix_result(suite_instance.run(self))
      @assertions = suite_instance._assertions
    end
    
    def puke(suite, test, exception)
      case exception
      when MiniTest::Skip then [:skip, exception]
      when MiniTest::Assertion then [:failure, exception]
      else [:error, exception]
      end
    end
    
    private
    
    def fix_result(result)
      result == '.' ? [:pass, nil] : result
    end
  end
end<commit_msg>Added option as an attribute to test_runner<commit_after>module MiniTest
  # Runner for individual MiniTest tests.
  # 
  # You *should not* create instances of this class directly. Instances of
  # {SuiteRunner} will create these and send them to the reporters.
  # 
  # Based upon <NAME> of Seattle.rb's MiniTest (MIT License).
  # 
  # @see https://github.com/seattlerb/minitest MiniTest
  class TestRunner
    attr_reader :suite, :test, :assertions, :result, :exception, :options
    
    def initialize(suite, test)
      @suite = suite
      @test = test
      @assertions = 0
    end
    
    def run
      suite_instance = suite.new(test)
      @result, @exception = fix_result(suite_instance.run(self))
      @assertions = suite_instance._assertions
    end
    
    def puke(suite, test, exception)
      case exception
      when MiniTest::Skip then [:skip, exception]
      when MiniTest::Assertion then [:failure, exception]
      else [:error, exception]
      end
    end
    
    private
    
    def fix_result(result)
      result == '.' ? [:pass, nil] : result
    end
  end
end
{'fraction_non_alphanumeric': 0.09285051067780872, 'fraction_numerical': 0.0009285051067780873, 'mean_word_length': 2.6774744027303754, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 5, 'https://': 2, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '2822564', 'n_tokens_mistral': 658, 'n_tokens_neox': 647, 'n_words': 202}