Module: Cucover::Recording::CoveredFile::HasLineNumberDetail

Defined in:
lib/cucover/recording/covered_file.rb

Instance Method Summary collapse

Instance Method Details

#covered_linesObject



41
42
43
44
45
46
47
48
49
50
# File 'lib/cucover/recording/covered_file.rb', line 41

def covered_lines
  return @covered_lines if @covered_lines

  @covered_lines = []
  @rcov_marked_info.each_with_index do |covered, index|
    line_number = index + Cucover::LineNumbers.offset
    @covered_lines << line_number if covered
  end
  @covered_lines
end