Sha256: 49ae9af060f0ef7a018958dcbb2e5954b42f89e382a690f16f9dd7f5760f8f0a
Contents?: true
Size: 542 Bytes
Versions: 10
Compression:
Stored size: 542 Bytes
Contents
require 'text-table' module Snuffle module Formatters class Text include Formatters::Base def header columns.map(&:titleize) end def export table = ::Text::Table.new table.head = header table.rows = rows table.to_s end def rows summary.cohorts.group_by{|c| c.values}.map do |cohort| [summary.path_to_file, summary.class_name, "#{cohort[0].join(', ')}", cohort[1].map(&:line_numbers).join(", ")] end end end end end
Version data entries
10 entries across 10 versions & 1 rubygems