method
start_dump
1.3.0 -
Show latest stable
- Class:
Spec::Runner::Formatter::ProfileFormatter
start_dump()public
No documentation available.
# File lib/spec/runner/formatter/profile_formatter.rb, line 30
def start_dump
super
@output.puts "\n\nTop 10 slowest examples:\n"
@example_times = @example_times.sort_by do |description, example, time|
time
end.reverse
@example_times[0..9].each do |description, example, time|
@output.print red(sprintf("%.7f", time))
@output.puts " #{description} #{example}"
end
@output.flush
end