diff options
author | Nathan Vonnahme <n8v@users.sourceforge.net> | 2006-11-10 01:26:16 +0000 |
---|---|---|
committer | Nathan Vonnahme <n8v@users.sourceforge.net> | 2006-11-10 01:26:16 +0000 |
commit | d84da4e2ec8569b8ff15356b6881df307c7333ca (patch) | |
tree | 16dd035b8a5aaaec75f7571eb78e21069f200049 /t/Nagios-Plugin-02.t | |
parent | 2d5e416592ff2fab507bd4ebfacab3a66a3b8e46 (diff) | |
download | monitoring-plugin-perl-d84da4e2ec8569b8ff15356b6881df307c7333ca.tar.gz |
* exposed Getopt and Threshold functionality from top level Nagios::Plugin
* exchanged Class::Struct for Class::Accessor
* POD is not updated yet.
git-svn-id: https://nagiosplug.svn.sourceforge.net/svnroot/nagiosplug/Nagios-Plugin/trunk@1536 f882894a-f735-0410-b71e-b25c423dba1c
Diffstat (limited to 't/Nagios-Plugin-02.t')
-rw-r--r-- | t/Nagios-Plugin-02.t | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/t/Nagios-Plugin-02.t b/t/Nagios-Plugin-02.t index 360e180..15ae3d6 100644 --- a/t/Nagios-Plugin-02.t +++ b/t/Nagios-Plugin-02.t | |||
@@ -16,7 +16,7 @@ is(UNKNOWN, $ERRORS{UNKNOWN}, "UNKNOWN => $ERRORS{UNKNOWN}"); | |||
16 | is(DEPENDENT, $ERRORS{DEPENDENT}, "DEPENDENT => $ERRORS{DEPENDENT}"); | 16 | is(DEPENDENT, $ERRORS{DEPENDENT}, "DEPENDENT => $ERRORS{DEPENDENT}"); |
17 | 17 | ||
18 | my $plugin = 'TEST_PLUGIN'; | 18 | my $plugin = 'TEST_PLUGIN'; |
19 | my $np = Nagios::Plugin->new( shortname => $plugin ); | 19 | my $np = Nagios::Plugin->new( shortname => $plugin, usage => "dummy usage" ); |
20 | is($np->shortname, $plugin, "shortname() is $plugin"); | 20 | is($np->shortname, $plugin, "shortname() is $plugin"); |
21 | 21 | ||
22 | # Test nagios_exit( CONSTANT, $msg ), nagios_exit( $string, $msg ) | 22 | # Test nagios_exit( CONSTANT, $msg ), nagios_exit( $string, $msg ) |
@@ -151,7 +151,7 @@ for (@ok) { | |||
151 | # shortname testing | 151 | # shortname testing |
152 | SKIP: { | 152 | SKIP: { |
153 | skip "requires File::Basename", 2 unless eval { require File::Basename }; | 153 | skip "requires File::Basename", 2 unless eval { require File::Basename }; |
154 | $np = Nagios::Plugin->new; | 154 | $np = Nagios::Plugin->new (usage => "dummy usage", version => "1"); |
155 | $plugin = uc File::Basename::basename($0); | 155 | $plugin = uc File::Basename::basename($0); |
156 | $plugin =~ s/\..*$//; | 156 | $plugin =~ s/\..*$//; |
157 | is($np->shortname, $plugin, "shortname() is '$plugin'"); | 157 | is($np->shortname, $plugin, "shortname() is '$plugin'"); |