Sha256: f459774cef101ec697b16329eb9ecbcf524741b11029ac426128133f675da7be
Contents?: true
Size: 1.21 KB
Versions: 1
Compression:
Stored size: 1.21 KB
Contents
Feature: NagiosPlugin Usage In order to write awesome Nagios Plugins with minimal effort As a busy (developer|sysadmin|devop|hacker|superhero|rockstar) I want to use the one NagiosPlugin framework Scenario Outline: Subclass from NagiosPlugin Given a file named "check_fancy.rb" with: """ require 'nagiosplugin' class FancyPlugin < NagiosPlugin::Plugin def critical? <critical> end def warning? <warning> end def ok? <ok> end def message 'answer is 42' end end FancyPlugin.new.check! """ When I run `ruby check_fancy.rb` Then the exit status should be <code> And the stdout should contain exactly: """ <stdout> """ Examples: | critical | warning | ok | status | code | stdout | | true | true | true | CRITICAL | 2 | FANCY CRITICAL: answer is 42 | | false | true | true | WARNING | 1 | FANCY WARNING: answer is 42 | | false | false | true | OK | 0 | FANCY OK: answer is 42 | | false | false | false | UNKNOWN | 3 | FANCY UNKNOWN: answer is 42 |
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
nagiosplugin-2.0.0 | features/nagiosplugin_usage.feature |