Class: TurnipFormatter::Step

Inherits:
Object
  • Object
show all
Defined in:
lib/turnip_formatter/step.rb,
lib/turnip_formatter/step/failure.rb,
lib/turnip_formatter/step/pending.rb

Defined Under Namespace

Modules: Failure, Pending

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(description) ⇒ Step

Returns a new instance of Step.



7
8
9
10
11
12
# File 'lib/turnip_formatter/step.rb', line 7

def initialize(description)
  step_name, keyword, docstring = description
  @name = keyword + step_name
  @docs = {}
  @docs[:extra_args] = docstring unless docstring.empty?
end

Instance Attribute Details

#docsObject (readonly)

Returns the value of attribute docs.



5
6
7
# File 'lib/turnip_formatter/step.rb', line 5

def docs
  @docs
end

#nameObject (readonly)

Returns the value of attribute name.



5
6
7
# File 'lib/turnip_formatter/step.rb', line 5

def name
  @name
end

Instance Method Details

#attention?Boolean

Returns:

  • (Boolean)


14
15
16
# File 'lib/turnip_formatter/step.rb', line 14

def attention?
  false
end