diff options
author | Nathan Vonnahme <n8v@users.sourceforge.net> | 2006-11-15 02:11:10 +0000 |
---|---|---|
committer | Nathan Vonnahme <n8v@users.sourceforge.net> | 2006-11-15 02:11:10 +0000 |
commit | 22509ac75b3ae04f35b22c87bbd85c643bb1db2b (patch) | |
tree | 8423e25fd60ca9c275aa890817b96ae9d50d168f /t/Nagios-Plugin-02.t | |
parent | 79b36b4d71afeb016a3b4764b6b484754323b011 (diff) | |
download | monitoring-plugin-perl-22509ac75b3ae04f35b22c87bbd85c643bb1db2b.tar.gz |
made 'usage' unmandatory in N::P::new().
git-svn-id: https://nagiosplug.svn.sourceforge.net/svnroot/nagiosplug/Nagios-Plugin/trunk@1538 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 15ae3d6..f64fb6f 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, usage => "dummy usage" ); | 19 | my $np = Nagios::Plugin->new( shortname => $plugin ); |
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 (usage => "dummy usage", version => "1"); | 154 | $np = Nagios::Plugin->new( 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'"); |