summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: e9f5442)
raw | patch | inline | side by side (parent: e9f5442)
author | Thomas Guyot-Sionnest <dermoth@aei.ca> | |
Wed, 18 Mar 2009 07:51:16 +0000 (03:51 -0400) | ||
committer | Thomas Guyot-Sionnest <dermoth@aei.ca> | |
Wed, 18 Mar 2009 07:51:16 +0000 (03:51 -0400) |
plugins/t/check_snmp.t | patch | blob | history |
diff --git a/plugins/t/check_snmp.t b/plugins/t/check_snmp.t
index 6d3dcb4ac844820820e7b897087bd390459e1008..646cfa430d25af98d1f13b2c7d10e092677ec740 100644 (file)
--- a/plugins/t/check_snmp.t
+++ b/plugins/t/check_snmp.t
use Test::More;
use NPTest;
-my $tests = 32;
+my $tests = 34;
plan tests => $tests;
my $res;
like($res->output, "/^SNMP CRITICAL - 2 *1*/", "Got two values back" );
like( $res->perf_output, "/ifIndex.2=2/", "Got 1st perf data" );
like( $res->perf_output, "/ifIndex.1=1/", "Got 2nd perf data" );
+
+ $res = NPTest->testCmd( "./check_snmp -H $host_snmp -C $snmp_community -o host.hrStorage.hrMemorySize.0,host.hrSystem.hrSystemProcesses.0 -w 1:,1: -c 1:,1:");
+ cmp_ok( $res->return_code, '==', 0, "Exit OK when querying hrMemorySize and hrSystemProcesses");
+ like($res->output, '/^SNMP OK - \d+ \d+/', "String contains hrMemorySize and hrSystemProcesses");
}
SKIP: {