Source: show | on GitHub
# File activesupport/lib/active_support/testing/performance.rb, line 282 def format(measurement) if measurement < 1 '%d ms' % (measurement * 1000) else '%.2f sec' % measurement end end
# File activesupport/lib/active_support/testing/performance.rb, line 278 def measure ::Time.now.to_f end