On 4 May 2011, at 16:33, Jochen Bern wrote:
> On 05/04/2011 02:18 PM, Jochen Bern wrote:
>> On 05/04/2011 01:17 PM, Ton Voon wrote:
>>> Hi Jochen,
>>> Is it possible if you can create a test case for this? Hit the =
status.cgi
>>> with this sortoption and then check that the hosts are ordered =
appropriately?
>>> There are some examples of tests in t/ that do similar tricks.
>> Does a "nagios -v" do the nagios_user:nagios_group set[ug]id() stuff
>> before starting the check? Because I work under a mode-750 /root =
while
>> t/etc/nagios.cfg specifies nagios:nagios ...
>=20
> Apparently it does; moving stuff over to ~nagios fixed "make =
test-perl"
> at least. ("make test-tap" is lacking an appropriate configuration, =
but
> it's operating outside the t/ subdir you referred me to, anyway.)
>=20
> Additional t/ stuff in the attached tarfile (it's all *new* files, not
> much sense in providing a "diff", is there?
>=20
>> [nagios@nagios t]$ prove -v 611cgistatus-hosturgencies.t
>> 611cgistatus-hosturgencies....1..3
>> ok 1 - List of hosts sorted by ascending name
>> ok 2 - List of hosts sorted by ascending status
>> ok 3 - List of hosts sorted by descending urgency
>> ok
>> All tests successful.
>> Files=3D1, Tests=3D3, 0 wallclock secs ( 0.06 cusr + 0.01 csys =3D =
0.07 CPU)
Brilliant - the test is great. Thanks.
I've committed this now. I've changed the sort order number from 16834 =
to 9 - not sure why it needs to be a completely different number.
Ton
This post was automatically imported from historical nagios-devel mailing list archives
Original poster: [email protected]