Commit b0a6e5ff authored by Michal 'vorner' Vaner's avatar Michal 'vorner' Vaner
Browse files

[2582] Lettuce tests for msgq logging

This way we check the logging works to the correct place and that the
configuration is handled. It is better checked by lettuce than unit
tests, since there's a lot of inter-module communication in it.
parent 2283402c
......@@ -40,7 +40,7 @@ import isc.cc
isc.util.process.rename()
isc.log.init("b10-msgq")
isc.log.init("b10-msgq", buffer=True)
# Logger that is used in the actual msgq handling - startup, shutdown and the
# poller thread.
logger = isc.log.Logger("msgq")
......
......@@ -562,6 +562,5 @@ class ThreadTests(unittest.TestCase):
self.assertTrue(self.__result)
if __name__ == '__main__':
isc.log.init("b10-msgq")
isc.log.resetUnitTestRootLogger()
unittest.main()
Feature: Message queue tests
Tests for the message queue daemon.
Scenario: logging
# We check the message queue logs.
Given I have bind10 running with configuration default.config
And wait for bind10 stderr message BIND10_STARTED_CC
And wait for bind10 stderr message MSGQ_START
And wait for bind10 stderr message MSGQ_LISTENER_STARTED
And wait for bind10 stderr message MSGQ_CFGMGR_SUBSCRIBED
And wait for bind10 stderr message CMDCTL_STARTED
# Check it handles configuration. The configuration is invalid,
# but it should get there anyway and we abuse it.
# TODO: Once it has any kind of real command or configuration
# value, use that instead.
Then set bind10 configuration Msgq to {"nonsense": 1}
And wait for bind10 stderr message MSGQ_CONFIG_DATA
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment