From b853f3a9868ea76ede271f21aad6aebe98cd1e4a Mon Sep 17 00:00:00 2001 From: Kovid Goyal Date: Thu, 20 Mar 2025 08:50:53 +0530 Subject: [PATCH] Show timeout duration in error --- kitty_tests/__init__.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/kitty_tests/__init__.py b/kitty_tests/__init__.py index ce4848682..21fedbe61 100644 --- a/kitty_tests/__init__.py +++ b/kitty_tests/__init__.py @@ -407,7 +407,7 @@ class PTY: msg = 'The condition was not met' if timeout_msg is not None: msg = timeout_msg() - raise TimeoutError(f'Timed out: {msg}. Screen contents: \n {repr(self.screen_contents())}') + raise TimeoutError(f'Timed out after {timeout} seconds: {msg}. Screen contents: \n {repr(self.screen_contents())}') def wait_till_child_exits(self, timeout=30 if BaseTest.is_ci else 10, require_exit_code=None): end_time = time.monotonic() + timeout