class Poke::Poke

Public Class Methods

new(checks, outputer) click to toggle source

Constructor

# File lib/poke.rb, line 26
def initialize(checks, outputer)
  @checks = checks
  @outputer = outputer
end

Public Instance Methods

run() click to toggle source

Launch all checks in the same time

# File lib/poke.rb, line 33
def run
  @outputer.on_start(@checks)

  @checks.each_with_index do |check, index|
    @outputer.on_check_before(check, index)
    returncode, message = check.run
    @outputer.on_check_after(check, {:returncode => returncode, :message => message})
  end

  @outputer.on_end
end