Class: Evilution::Result::CoverageGap Private
- Inherits:
-
Object
- Object
- Evilution::Result::CoverageGap
- Defined in:
- lib/evilution/result/coverage_gap.rb
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.
Instance Attribute Summary collapse
- #file_path ⇒ Object readonly private
- #line ⇒ Object readonly private
- #mutation_results ⇒ Object readonly private
- #subject_name ⇒ Object readonly private
Instance Method Summary collapse
- #count ⇒ Object private
-
#initialize(file_path:, subject_name:, line:, mutation_results:) ⇒ CoverageGap
constructor
private
A new instance of CoverageGap.
- #operator_names ⇒ Object private
- #primary_diff ⇒ Object private
- #primary_operator ⇒ Object private
- #single? ⇒ Boolean private
Constructor Details
#initialize(file_path:, subject_name:, line:, mutation_results:) ⇒ CoverageGap
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.
Returns a new instance of CoverageGap.
8 9 10 11 12 13 14 |
# File 'lib/evilution/result/coverage_gap.rb', line 8 def initialize(file_path:, subject_name:, line:, mutation_results:) @file_path = file_path @subject_name = subject_name @line = line @mutation_results = mutation_results.dup.freeze freeze end |
Instance Attribute Details
#file_path ⇒ Object (readonly)
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.
6 7 8 |
# File 'lib/evilution/result/coverage_gap.rb', line 6 def file_path @file_path end |
#line ⇒ Object (readonly)
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.
6 7 8 |
# File 'lib/evilution/result/coverage_gap.rb', line 6 def line @line end |
#mutation_results ⇒ Object (readonly)
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.
6 7 8 |
# File 'lib/evilution/result/coverage_gap.rb', line 6 def mutation_results @mutation_results end |
#subject_name ⇒ Object (readonly)
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.
6 7 8 |
# File 'lib/evilution/result/coverage_gap.rb', line 6 def subject_name @subject_name end |
Instance Method Details
#count ⇒ 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.
28 29 30 |
# File 'lib/evilution/result/coverage_gap.rb', line 28 def count mutation_results.length end |
#operator_names ⇒ 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.
16 17 18 |
# File 'lib/evilution/result/coverage_gap.rb', line 16 def operator_names mutation_results.map { |r| r.mutation.operator_name }.uniq end |
#primary_diff ⇒ 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.
24 25 26 |
# File 'lib/evilution/result/coverage_gap.rb', line 24 def primary_diff mutation_results.first.mutation.diff end |
#primary_operator ⇒ 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.
20 21 22 |
# File 'lib/evilution/result/coverage_gap.rb', line 20 def primary_operator mutation_results.first.mutation.operator_name end |
#single? ⇒ 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.
32 33 34 |
# File 'lib/evilution/result/coverage_gap.rb', line 32 def single? count == 1 end |