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-01.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-01.t')
-rw-r--r-- | t/Nagios-Plugin-01.t | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/t/Nagios-Plugin-01.t b/t/Nagios-Plugin-01.t index a73fce4..db12c35 100644 --- a/t/Nagios-Plugin-01.t +++ b/t/Nagios-Plugin-01.t | |||
@@ -11,16 +11,16 @@ Nagios::Plugin::Functions::_fake_exit(1); | |||
11 | diag "\nusing Nagios::Plugin revision ". $Nagios::Plugin::VERSION . "\n" | 11 | diag "\nusing Nagios::Plugin revision ". $Nagios::Plugin::VERSION . "\n" |
12 | if $ENV{TEST_VERBOSE}; | 12 | if $ENV{TEST_VERBOSE}; |
13 | 13 | ||
14 | my $p = Nagios::Plugin->new (usage => "dummy usage"); | 14 | my $p = Nagios::Plugin->new(); |
15 | isa_ok( $p, "Nagios::Plugin"); | 15 | isa_ok( $p, "Nagios::Plugin"); |
16 | 16 | ||
17 | $p->shortname("PAGESIZE"); | 17 | $p->shortname("PAGESIZE"); |
18 | is($p->shortname, "PAGESIZE", "shortname explicitly set correctly"); | 18 | is($p->shortname, "PAGESIZE", "shortname explicitly set correctly"); |
19 | 19 | ||
20 | $p = Nagios::Plugin->new (usage => "dummy usage"); | 20 | $p = Nagios::Plugin->new(); |
21 | is($p->shortname, "NAGIOS-PLUGIN-01", "shortname should default on new"); | 21 | is($p->shortname, "NAGIOS-PLUGIN-01", "shortname should default on new"); |
22 | 22 | ||
23 | $p = Nagios::Plugin->new( shortname => "SIZE", usage => "dummy usage" ); | 23 | $p = Nagios::Plugin->new( shortname => "SIZE", () ); |
24 | is($p->shortname, "SIZE", "shortname set correctly on new"); | 24 | is($p->shortname, "SIZE", "shortname set correctly on new"); |
25 | 25 | ||
26 | diag "warn if < 10, critical if > 25 " if $ENV{TEST_VERBOSE}; | 26 | diag "warn if < 10, critical if > 25 " if $ENV{TEST_VERBOSE}; |