Method: CodeWeb::HtmlReport#report
- Defined in:
- lib/code_web/html_report.rb
#report ⇒ Object
124 125 126 127 128 129 130 131 132 |
# File 'lib/code_web/html_report.rb', line 124 def report template = ERB.new(TEMPLATE, nil, "-") @out.puts template.result(binding) rescue => e e.backtrace.detect { |l| l =~ /\(erb\):([0-9]+)/ } line_no=$1.to_i raise RuntimeError, "error in #{__FILE__}:#{line_no+28} #{e}\n\n #{TEMPLATE.split(/\n/)[line_no-1]}\n\n ", e.backtrace end |