Condition Coverage

blib/lib/Monitoring/Plugin/Functions.pm
Criterion Covered Total %
condition 42 63 66.6


and 3 conditions

line !l l&&!r l&&r condition
93 2 93 0 defined $code and $code eq 'return_code' || $code eq 'message'
95 0 0 6 int @_ / 2 != @_ / 2 and ref $_[$#_]
107 2 63 30 defined $code and exists $ERRORS{$code}
110 2 8 85 defined $code and exists $STATUS_TEXT{$code}
112 95 0 0 ref $message and ref $message eq 'ARRAY'
121 0 8 87 defined $message and $message ne ''
130 0 42 6 $plugin->perfdata and $plugin->all_perfoutput
167 2 47 6 defined $arg1 and $arg1 eq 'return_code' || $arg1 eq 'message'
2 47 0 defined $arg1 and exists $ERRORS{$arg1} || exists $STATUS_TEXT{$arg1}
5 24 0 defined $arg2 and exists $ERRORS{$arg2} || exists $STATUS_TEXT{$arg2}

or 2 conditions

line l !l condition
104 48 47 $arg ||= {}
221 0 21 $code ||= 2
222 19 18 $code ||= 1

or 3 conditions

line l !l&&r !l&&!r condition
64 0 67 0 $shortname || $ENV{'PLUGIN_NAME'} || $ENV{'NAGIOS_PLUGIN'} || $0
93 6 0 87 $code eq 'return_code' || $code eq 'message'
126 48 47 0 $shortname ||= get_shortname()
167 6 0 47 $arg1 eq 'return_code' || $arg1 eq 'message'
10 0 37 exists $ERRORS{$arg1} || exists $STATUS_TEXT{$arg1}
10 0 14 exists $ERRORS{$arg2} || exists $STATUS_TEXT{$arg2}
237 0 13 0 $message ||= join($arg{'join'}, @{$arg{'critical'};})
239 0 10 0 $message ||= join($arg{'join'}, @{$arg{'warning'};})
242 18 8 1 $message ||= ref $arg{'ok'} ? join($arg{'join'}, @{$arg{'ok'};}) : $arg{'ok'}