Module: Cucumber::Formatter::Duration
- Included in:
- Console, Html, Runtime, Runtime::FeaturesLoader
- Defined in:
- lib/cucumber/formatter/duration.rb
Instance Method Summary (collapse)
-
- (Object) format_duration(seconds)
Helper method for formatters that need to format a duration in seconds to the UNIX time format.
Instance Method Details
- (Object) format_duration(seconds)
Helper method for formatters that need to format a duration in seconds to the UNIX time format.
7 8 9 10 |
# File 'lib/cucumber/formatter/duration.rb', line 7 def format_duration(seconds) m, s = seconds.divmod(60) "#{m}m#{'%.3f' % s}s" end |