From 39b890a20cec87ed8edb7aca533281c479dcfa4d Mon Sep 17 00:00:00 2001 From: adamXbot <111877622+adamXbot@users.noreply.github.com> Date: Wed, 11 Nov 2026 00:17:05 +1100 Subject: [PATCH] Give the dialog capture test's Node helper room to start on a slow runner The Windows unit tests failed on main after #106 with a timeout in test_draw_failure_releases_snapshot_and_dismisses_prompt. The test runs a short script under Node and allowed it ten seconds. The script itself takes milliseconds; the time is Node starting, and this test is the first in the job to start it. That first start takes a little over two seconds on the Windows runner normally. On that run every later start was ten times slower than usual as well, and the first one passed the limit. The same tree had passed the same job on the pull request minutes earlier. The limit is now 120 seconds: still an end to a real hang, no longer a measure of the runner. Co-Authored-By: Claude Fable 5.2 --- tests/test_dialog_capture.py | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/tests/test_dialog_capture.py b/tests/test_dialog_capture.py index 5e07aa4..d44dd44 100644 --- a/tests/test_dialog_capture.py +++ b/tests/test_dialog_capture.py @@ -77,11 +77,15 @@ @unittest.skipUnless(shutil.which("node"), "dialog script checks require Node") class DialogSnapshotTests(unittest.TestCase): def run_script(self, scale=1, fail_draw=False): + # The script finishes in milliseconds; the time goes on starting Node. + # The first start in a Windows CI job takes over two seconds on a + # good day and passed ten on a slow runner, failing a test that had + # nothing wrong with it. The limit is only there to stop a real hang. result = subprocess.run( [shutil.which("node"), "-e", HARNESS], input=json.dumps({"source": core.DIALOG_VIEW, "scale": scale, "failDraw": fail_draw}), - text=True, capture_output=True, check=True, timeout=10, + text=True, capture_output=True, check=True, timeout=120, ) return json.loads(result.stdout)