Give the stalled-fetch test a timeout that a loaded runner fits in #621

Merged
lilleman merged 5 commits from item-439 into main 2026-11-18 22:50:24 +01:00
Showing only changes of commit 34605579b8 - Show all commits
+1 -1
View File
@@ -303,7 +303,7 @@ class ChunkPreflightTool(unittest.TestCase):
def test_reads_origin_as_last_fetched_where_the_fetch_stalls_and_still_states_the_other_facts(self):
repo = Repo(self)
repo.stub_git(f'"fetch --quiet origin") exec {shutil.which("sleep")} 30;;')
# The timeout also bounds `reading-cost`, so it stays well above what that takes on a loaded runner.
# The timeout also stops `reading-cost`, so it is set well above the seconds `reading-cost` takes on a loaded runner.
done = repo.preflight("--worktree", CHUNK_PREFLIGHT_TIMEOUT="5")
self.assertEqual(done.returncode, 0, done.stderr)
self.assertIn("as last fetched", done.stdout)