Class: ForemanMaintain::Runner::StoredExecution

Inherits:
Execution
  • Object
show all
Extended by:
Forwardable
Includes:
Concerns::Logger
Defined in:
lib/foreman_maintain/runner/stored_execution.rb

Overview

Class representing an execution of a single step in scenario

Instance Attribute Summary

Attributes inherited from Execution

#ended_at, #output, #started_at, #status, #step

Instance Method Summary collapse

Methods included from Concerns::Logger

#logger

Methods inherited from Execution

#aborted?, #fail?, #info_warning?, #name, #skip?, #skipped?, #storage, #success?, #update, #warning?, #whitelisted?

Constructor Details

#initialize(step, hash) ⇒ StoredExecution

Returns a new instance of StoredExecution.



8
9
10
11
12
# File 'lib/foreman_maintain/runner/stored_execution.rb', line 8

def initialize(step, hash)
  @step = step
  @status = hash[:status]
  @output = hash[:output]
end

Instance Method Details

#reporterObject



14
15
16
# File 'lib/foreman_maintain/runner/stored_execution.rb', line 14

def reporter
  raise 'Can not access reporter from stored execution'
end

#runObject



18
19
20
# File 'lib/foreman_maintain/runner/stored_execution.rb', line 18

def run
  raise 'Can not run stored execution'
end