class Cucumber::Messages::PickleStepArgument

Represents the PickleStepArgument message in Cucumber’s message protocol.

An optional argument

Attributes

data_table[R]
doc_string[R]

Public Class Methods

from_h(hash) click to toggle source

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

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

  new(
    doc_string: PickleDocString.from_h(hash[:docString]),
    data_table: PickleTable.from_h(hash[:dataTable])
  )
end
new( doc_string: nil, data_table: nil ) click to toggle source
Calls superclass method
# File lib/cucumber/messages/pickle_step_argument.rb, line 17
def initialize(
  doc_string: nil,
  data_table: nil
)
  @doc_string = doc_string
  @data_table = data_table
  super()
end