class GCOV::ANSIIFormatter
Public Class Methods
new(project)
click to toggle source
# File lib/ansii_formatter.rb, line 12 def initialize project @project = project end
Public Instance Methods
print()
click to toggle source
# File lib/ansii_formatter.rb, line 16 def print @project.files.each do |file| puts "#{white}#{bold}=== #{file.meta['Source']} ===#{reset}" file.lines.select{|line| line.number > 0}.each do |line| col = case line.count when :none then dark+white when :missed then black+on_red else green end puts col + line.text + reset end end end