Class: Mutant::Integration::Minitest::TestCase
- Inherits:
-
Object
- Object
- Mutant::Integration::Minitest::TestCase
- Includes:
- Adamantium
- Defined in:
- lib/mutant/integration/minitest.rb
Overview
Compose a runnable with test method
This looks actually like a missing object on minitest implementation.
Instance Method Summary collapse
-
#call(reporter) ⇒ Boolean
Run test case.
-
#expressions(parser) ⇒ Array<Expression>
Parse expressions.
-
#identification ⇒ String
Identification string.
Instance Method Details
#call(reporter) ⇒ Boolean
Run test case
45 46 47 48 49 50 51 52 53 |
# File 'lib/mutant/integration/minitest.rb', line 45 def call(reporter) # Minitest 6.0+ renamed run_one_method to run if ::Minitest::Runnable.respond_to?(:run_one_method) ::Minitest::Runnable.run_one_method(klass, test_method, reporter) else ::Minitest::Runnable.run(klass, test_method, reporter) end reporter.passed? end |
#expressions(parser) ⇒ Array<Expression>
Parse expressions
60 61 62 63 64 |
# File 'lib/mutant/integration/minitest.rb', line 60 def expressions(parser) klass.resolve_cover_expressions.to_a.map do |value| parser.call((value)).from_right end end |
#identification ⇒ String
Identification string
37 |
# File 'lib/mutant/integration/minitest.rb', line 37 def identification = IDENTIFICATION_FORMAT % [klass, test_method] |