Class: Highway::Steps::Step

Inherits:
Object
  • Object
show all
Defined in:
lib/highway/steps/step.rb

Overview

This class serves as a base class for all step definition classes. It contains a common API and some useful utilities.

Class Method Summary collapse

Class Method Details

.nameString

Name of the step as it appears in configuration file.

Returns:

  • (String)

Raises:

  • (NotImplementedError)


20
21
22
# File 'lib/highway/steps/step.rb', line 20

def self.name
  raise NotImplementedError.new("You must override `#{__method__.to_s}` in `#{self.class.to_s}`.")
end

.parametersArray<Highway::Steps::Parameters::*>

Parameters that this step recognizes.

Returns:

Raises:

  • (NotImplementedError)


27
28
29
# File 'lib/highway/steps/step.rb', line 27

def self.parameters
  raise NotImplementedError.new("You must override `#{__method__.to_s}` in `#{self.class.to_s}`.")
end

.root_parameterHighway::Steps::Parameters::Compound

The root parameter that nests all parameters of the step.



34
35
36
# File 'lib/highway/steps/step.rb', line 34

def self.root_parameter
  return Parameters::Compound.new(name: "root", required: true, defaults: true, children: parameters)
end

.run(parameters:, context:, report:) ⇒ Void

Run the step in given context containing inputs and Fastlane runner.

Parameters:

Returns:

  • (Void)

Raises:

  • (NotImplementedError)


45
46
47
# File 'lib/highway/steps/step.rb', line 45

def self.run(parameters:, context:, report:)
  raise NotImplementedError.new("You must override `#{__method__.to_s}` in `#{self.class.to_s}`.")
end