class Cucumber::Core::Test::Result::Duration

def initialize(nanoseconds)

def initialize(nanoseconds)
  @nanoseconds = nanoseconds
end

def to_message_duration

def to_message_duration
  duration_hash = seconds_to_duration(nanoseconds.to_f / NANOSECONDS_PER_SECOND)
  duration_hash.transform_keys! do |key|
    key.to_sym
  rescue Error
    return key
  end
  Cucumber::Messages::Duration.from_h(duration_hash)
end