Skip to content

Commit

Permalink
fix some tests
Browse files Browse the repository at this point in the history
  • Loading branch information
wdpypere committed Oct 31, 2024
1 parent 7ed68d0 commit abea029
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions test/nagios_simple.py
Original file line number Diff line number Diff line change
Expand Up @@ -129,22 +129,22 @@ def test_simple_single_instance(self):
kwargs.update(kwargsmore)

# critical value in message
self._basic_test_single_instance(kwargs, 'CRITICAL value1 | value0=3;5;10; value1=15;5;10; value2=7;5;10;',
self._basic_test_single_instance(kwargs, 'CRITICAL value1, hello | value0=3;5;10; value1=15;5;10; value2=7;5;10;',
NAGIOS_EXIT_CRITICAL)

# all warning values in message
kwargs['value1'] = 7
self._basic_test_single_instance(
kwargs, 'WARNING value1, value2 | value0=3;5;10; value1=7;5;10; value2=7;5;10;', NAGIOS_EXIT_WARNING)
kwargs, 'WARNING value1, value2, hello | value0=3;5;10; value1=7;5;10; value2=7;5;10;', NAGIOS_EXIT_WARNING)

# warning in message
kwargs['value1'] = 5
self._basic_test_single_instance(kwargs, 'WARNING value2 | value0=3;5;10; value1=5;5;10; value2=7;5;10;',
self._basic_test_single_instance(kwargs, 'WARNING value2, hello | value0=3;5;10; value1=5;5;10; value2=7;5;10;',
NAGIOS_EXIT_WARNING)

# no warning/critical; so regular message
kwargs['value2'] = 5
self._basic_test_single_instance(kwargs, 'OK hello | value0=3;5;10; value1=5;5;10; value2=5;5;10;',
self._basic_test_single_instance(kwargs, 'OK hello, hello | value0=3;5;10; value1=5;5;10; value2=5;5;10;',
NAGIOS_EXIT_OK)


Expand Down

0 comments on commit abea029

Please sign in to comment.