class Cucumber::Messages::TestRunFinished

Attributes

exception[R]

Any exception thrown during the test run, if any. Does not include exceptions thrown while executing steps.

message[R]

An informative message about the test run. Typically additional information about failure, but not necessarily.

success[R]

A test run is successful if all steps are either passed or skipped, all before/after hooks passed and no other exceptions where thrown.

timestamp[R]

Timestamp when the TestRun is finished

Public Class Methods

from_h(hash) click to toggle source

Returns a new TestRunFinished from the given hash. If the hash keys are camelCased, they are properly assigned to the corresponding snake_cased attributes.

Cucumber::Messages::TestRunFinished.from_h(some_hash) # => #<Cucumber::Messages::TestRunFinished:0x... ...>
# File lib/cucumber/messages.deserializers.rb, line 1071
def self.from_h(hash)
  return nil if hash.nil?

  self.new(
    message: hash[:message],
    success: hash[:success],
    timestamp: Timestamp.from_h(hash[:timestamp]),
    exception: Exception.from_h(hash[:exception]),
  )
end
new( message: nil, success: false, timestamp: Timestamp.new, exception: nil ) click to toggle source
# File lib/cucumber/messages.dtos.rb, line 1780
def initialize(
  message: nil,
  success: false,
  timestamp: Timestamp.new,
  exception: nil
)
  @message = message
  @success = success
  @timestamp = timestamp
  @exception = exception
end