[test] set flag before starting client
authorVictor Shyba <victor.shyba@gmail.com>
Tue, 28 Jul 2015 19:48:04 +0000 (16:48 -0300)
committerVictor Shyba <victor.shyba@gmail.com>
Tue, 28 Jul 2015 19:48:04 +0000 (16:48 -0300)
Test client will only start with flag set to True.
Change EventsGenericClientTestCase to set the flag on the
first line of setUp.

src/leap/common/tests/test_events.py

index 8f08eeb..2ad097e 100644 (file)
@@ -39,13 +39,13 @@ if 'DEBUG' in os.environ:
 class EventsGenericClientTestCase(object):
 
     def setUp(self):
+        flags.set_events_enabled(True)
         self._server = server.ensure_server(
             emit_addr="tcp://127.0.0.1:0",
             reg_addr="tcp://127.0.0.1:0")
         self._client.configure_client(
             emit_addr="tcp://127.0.0.1:%d" % self._server.pull_port,
             reg_addr="tcp://127.0.0.1:%d" % self._server.pub_port)
-        flags.set_events_enabled(True)
 
     def tearDown(self):
         self._client.shutdown()