Sha256: ade68c4e193352d36363bf20f119fe12b699a2bf6c698f46be1e4f611c696ef8
Contents?: true
Size: 621 Bytes
Versions: 35
Compression:
Stored size: 621 Bytes
Contents
# frozen_string_literal: true # # A ridiculously simple formatter for SimpleCov results. # module SimpleCov module Formatter class SimpleFormatter # Takes a SimpleCov::Result and generates a string out of it def format(result) output = "".dup result.groups.each do |name, files| output << "Group: #{name}\n" output << "=" * 40 output << "\n" files.each do |file| output << "#{file.filename} (coverage: #{file.covered_percent.round(2)}%)\n" end output << "\n" end output end end end end
Version data entries
35 entries across 23 versions & 3 rubygems