[nagiosplug] Fix check_by_ssh test for non-Bash login shells
"Nagios Plugin Development" <[email protected]> Fri, 22 Jun 2012 15:20:10 +0000
| Newsgroups | gmane.network.nagios.plugins.cvs |
|---|---|
| Message-ID | <[email protected]> |
Module: nagiosplug Branch: master Commit: e6df238350588afd93f11501c4c673b07c9733a4 Author: Holger Weiss <[email protected]> Date: Fri Jun 22 17:11:18 2012 +0200 URL: http://nagiosplug.git.sf.net/git/gitweb.cgi?p=nagiosplug/nagiosplug;a=commit;h=e6df238 Fix check_by_ssh test for non-Bash login shells In the C shell and in the Z shell, the "?" character must be quoted or backslash-escaped in order to use it verbatim. Therefore, a command such as check_by_ssh -H test.example.com -l joe echo huh? might fail, depending on joe's login shell on test.example.com. Just to make sure, this commit removes most punctuation characters from our test strings. --- plugins/t/check_by_ssh.t | 10 +++++----- 1 files changed, 5 insertions(+), 5 deletions(-) diff --git a/plugins/t/check_by_ssh.t b/plugins/t/check_by_ssh.t index cca72c9..8d1b190 100644 --- a/plugins/t/check_by_ssh.t +++ b/plugins/t/check_by_ssh.t @@ -27,11 +27,11 @@ plan skip_all => "SSH_HOST and SSH_IDENTITY must be defined" unless ($ssh_servic plan tests => 42; # Some random check strings/response -my @responce = ('OK: Everything is fine!', - 'WARNING: Hey, pick me, pick me!', - 'CRITICAL: Shit happens...', - 'UNKNOWN: What can I do for ya?', - 'WOOPS: What did I smoke?', +my @responce = ('OK: Everything is fine', + 'WARNING: Hey, pick me, pick me', + 'CRITICAL: Shit happens', + 'UNKNOWN: What can I do for ya', + 'WOOPS: What did I smoke', ); my @responce_re; my @check; ------------------------------------------------------------------------------ Live Security Virtual Conference Exclusive live event will cover all the ways today's security and threat landscape has changed and how IT managers can respond. Discussions will include endpoint security, mobile security and the latest in malware threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/