Class: Mutant::Result::TestEnv Private
- Inherits:
-
Object
- Object
- Mutant::Result::TestEnv
- Includes:
- Mutant::Result
- Defined in:
- lib/mutant/result.rb
Overview
This class is part of a private API. You should avoid using this class if possible, as it may be removed or be changed in the future.
TestEnv result object
Instance Method Summary collapse
- #amount_test_results ⇒ Object private
- #amount_tests ⇒ Object private
- #amount_tests_failed ⇒ Object private
- #amount_tests_success ⇒ Object private
-
#failed_test_results ⇒ Array<Result::Test>
private
Failed subject results.
- #stop? ⇒ Boolean private
-
#success? ⇒ Boolean
private
Test if run is successful.
- #testtime ⇒ Object private
Methods included from Mutant::Result
Instance Method Details
#amount_test_results ⇒ Object
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
146 147 148 |
# File 'lib/mutant/result.rb', line 146 def amount_test_results test_results.length end |
#amount_tests ⇒ Object
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
142 143 144 |
# File 'lib/mutant/result.rb', line 142 def amount_tests env.integration.all_tests.length end |
#amount_tests_failed ⇒ Object
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
150 151 152 |
# File 'lib/mutant/result.rb', line 150 def amount_tests_failed failed_test_results.length end |
#amount_tests_success ⇒ Object
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
154 155 156 |
# File 'lib/mutant/result.rb', line 154 def amount_tests_success test_results.count(&:passed) end |
#failed_test_results ⇒ Array<Result::Test>
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
Failed subject results
129 130 131 |
# File 'lib/mutant/result.rb', line 129 def failed_test_results test_results.reject(&:success?) end |
#stop? ⇒ Boolean
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
134 135 136 |
# File 'lib/mutant/result.rb', line 134 def stop? env.config.fail_fast && !test_results.all?(&:success?) end |
#success? ⇒ Boolean
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
Test if run is successful
121 122 123 |
# File 'lib/mutant/result.rb', line 121 def success? amount_tests_failed.equal?(0) end |
#testtime ⇒ Object
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
138 139 140 |
# File 'lib/mutant/result.rb', line 138 def testtime test_results.map(&:runtime).sum(0.0) end |