Module: SystemCheck::MultiCheckHelpers

Defined in:
lib/system_check/multi_check_helpers.rb

Overview

Helpers used inside a SystemCheck instance to standardize output responses when using a multi_check version

Instance Method Summary collapse

Instance Method Details



21
22
23
24
25
26
# File 'lib/system_check/multi_check_helpers.rb', line 21

def print_failure(reason)
  $stdout.puts 'no'.color(:red)

  $stdout.puts '  Reason:'.color(:blue)
  $stdout.puts "  #{reason}"
end


28
29
30
# File 'lib/system_check/multi_check_helpers.rb', line 28

def print_pass
  $stdout.puts self.class.check_pass.color(:green)
end


7
8
9
10
11
12
# File 'lib/system_check/multi_check_helpers.rb', line 7

def print_skipped(reason)
  $stdout.puts 'skipped'.color(:magenta)

  $stdout.puts '  Reason:'.color(:blue)
  $stdout.puts "  #{reason}"
end


14
15
16
17
18
19
# File 'lib/system_check/multi_check_helpers.rb', line 14

def print_warning(reason)
  $stdout.puts 'warning'.color(:magenta)

  $stdout.puts '  Reason:'.color(:blue)
  $stdout.puts "  #{reason}"
end