Class: AutomationObject::StepDefinitions::Parse

Inherits:
Object
  • Object
show all
Defined in:
lib/automation_object/step_definitions/support/parse.rb

Overview

Class to parse arguments passed through step definitions

Instance Method Summary collapse

Constructor Details

#initialize(args) ⇒ Parse

Returns a new instance of Parse

Parameters:

  • args (Array)

    input args from step definition



9
10
11
# File 'lib/automation_object/step_definitions/support/parse.rb', line 9

def initialize(args)
  @args = args
end

Instance Method Details

#getObject



13
14
15
16
17
18
19
20
# File 'lib/automation_object/step_definitions/support/parse.rb', line 13

def get
  parsed_args = []
  @args.each do |arg|
    parsed_args.push(parse(arg))
  end

  parsed_args
end