[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Negative testing
From: |
Barry Clarke |
Subject: |
Negative testing |
Date: |
Mon, 30 Jul 2012 14:45:10 +0100 |
Hello all
I'm running monit 5.2.5, under Fedora 17.
I'm looking to test that some service is /not/ available - we have an
admin interface on a system that I have to temporarily open to the
internet sometimes.
I want to be hassled about it to remind me to tidy up after myself.
I expected to be able to say:
+-------------------------------------------------------------------------------------------------------------------+
check host adminInterface with address 11.22.33.44
...
if succeeded port 234 type tcpssl protocol http then alert
+-------------------------------------------------------------------------------------------------------------------+
but "if succeeded" doesn't seem to be a valid clause, and I don't see
how to negate the test.
Instead I can:
+-------------------------------------------------------------------------------------------------------------------+
check host adminInterface with address 11.22.33.44
...
if failed port 234 type tcpssl protocol http then alert else
if succeeded then alert
+-------------------------------------------------------------------------------------------------------------------+
But this seems ugly, and I can't use 'with reminder'.
I imagine I'm missing a more elegant solution.
Has anybody else managed something better?
cheers
Barry
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- Negative testing,
Barry Clarke <=