diff --git a/Lib/test/test_logging.py b/Lib/test/test_logging.py index 7b5bc6b6a74180..c3c4de06fa0f09 100644 --- a/Lib/test/test_logging.py +++ b/Lib/test/test_logging.py @@ -2191,7 +2191,8 @@ def test_output(self): self.handled.clear() msg = "sp\xe4m" logger.error(msg) - self.handled.wait() + handled = self.handled.wait(support.SHORT_TIMEOUT) + self.assertTrue(handled, "HTTP request timed out") self.assertEqual(self.log_data.path, '/frob') self.assertEqual(self.command, method) if method == 'GET':