class Cucumber::Messages::TestStepFinished
Represents the TestStepFinished
message in Cucumber’s message protocol.
Attributes
test_case_started_id[R]
test_step_id[R]
test_step_result[R]
timestamp[R]
Public Class Methods
from_h(hash)
click to toggle source
Returns a new TestStepFinished
from the given hash. If the hash keys are camelCased, they are properly assigned to the corresponding snake_cased attributes.
Cucumber::Messages::TestStepFinished.from_h(some_hash) # => #<Cucumber::Messages::TestStepFinished:0x... ...>
# File lib/cucumber/messages/test_step_finished.rb, line 39 def self.from_h(hash) return nil if hash.nil? new( test_case_started_id: hash[:testCaseStartedId], test_step_id: hash[:testStepId], test_step_result: TestStepResult.from_h(hash[:testStepResult]), timestamp: Timestamp.from_h(hash[:timestamp]) ) end
new( test_case_started_id: '', test_step_id: '', test_step_result: TestStepResult.new, timestamp: Timestamp.new )
click to toggle source
Calls superclass method
# File lib/cucumber/messages/test_step_finished.rb, line 19 def initialize( test_case_started_id: '', test_step_id: '', test_step_result: TestStepResult.new, timestamp: Timestamp.new ) @test_case_started_id = test_case_started_id @test_step_id = test_step_id @test_step_result = test_step_result @timestamp = timestamp super() end