diff --git a/tests/log_handler_test.py b/tests/log_handler_test.py index e7c0cdba..a2e153ed 100644 --- a/tests/log_handler_test.py +++ b/tests/log_handler_test.py @@ -1,6 +1,7 @@ import logging import mock +import sys import unittest2 import testlib @@ -85,6 +86,11 @@ class StartupTest(testlib.RouterMixin, testlib.TestCase): expect = 'Parent is context %s (%s)' % (c1.context_id, 'parent') self.assertTrue(expect in logs) +StartupTest = unittest2.skipIf( + condition=sys.version_info < (2, 7), + reason="Message log flaky on Python < 2.7" +)(StartupTest) + if __name__ == '__main__': unittest2.main()