Class: RCheck::ReportPrinters::List
- Defined in:
- lib/rcheck/report_printers.rb
Instance Method Summary collapse
Methods inherited from Abstract
Methods included from Colors::Mixin
Constructor Details
This class inherits a constructor from RCheck::ReportPrinters::Abstract
Instance Method Details
#report(suite) ⇒ Object
14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 |
# File 'lib/rcheck/report_printers.rb', line 14 def report(suite) suite.local(*@opts[:show]).each do |item| item = item.result location = item.location.first cprint item.status, " %-8s #{location.short}:" % [item.status.capitalize] cputs :quiet, " (#{suite.full_name})" if (item.status == :pending) cputs(:quiet, *dbg_indent(item.introspection)) if item.reason else cprint :quiet, " %-8s " % [''] # TODO source inspect at error site puts location.source # if item.introspection && item.introspection.length > 2000 # puts item.class.inspect # end if item.introspection cprint(:value, *indent('> ')) cputs :quiet, item.introspection end puts end cputs :quiet, indent(item.backtrace) if [:error, :fail].include?(item.status) item.info.each do |dbg| cputs :quiet, dbg_indent(dbg) end end end # if suite.total(:error, :fail).any? # end suite.children.each do |child_suite| report child_suite end end |