Class: SimpleCov::RSpec::UncoveredReport Private
- Inherits:
-
Object
- Object
- SimpleCov::RSpec::UncoveredReport
- Defined in:
- lib/simplecov-rspec/uncovered_report.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.
Formats the "uncovered lines/branches/methods" report printed after a run: either a full listing of every uncovered item, or a per-criterion count with a hint on how to see the details.
Constant Summary collapse
- CRITERION_LABELS =
This constant is part of a private API. You should avoid using this constant if possible, as it may be removed or be changed in the future.
Maps a coverage criterion to its [singular, plural] noun, for report formatting
{ line: %w[line lines], branch: %w[branch branches], method: %w[method methods] }.freeze
Instance Method Summary collapse
-
#initialize(result:, criteria:, detail:, detail_env_var:) ⇒ UncoveredReport
constructor
private
Build a report for the given result, criteria, and detail level.
-
#to_s ⇒ String
private
The formatted report text, or an empty string if there is nothing to report.
Constructor Details
#initialize(result:, criteria:, detail:, detail_env_var:) ⇒ UncoveredReport
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.
Build a report for the given result, criteria, and detail level
27 28 29 30 31 32 |
# File 'lib/simplecov-rspec/uncovered_report.rb', line 27 def initialize(result:, criteria:, detail:, detail_env_var:) @result = result @criteria = criteria @detail = detail @detail_env_var = detail_env_var end |
Instance Method Details
#to_s ⇒ String
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.
The formatted report text, or an empty string if there is nothing to report
36 |
# File 'lib/simplecov-rspec/uncovered_report.rb', line 36 def to_s = detail ? detailed_text : summary_text |