Skip to content

Commit 667cfb5

Browse files
committed
Allow pause step between CoE attempt 1 and attempt 2
Update test_no_job_tolerates_failure to permit an optional pause step between a continue-on-error attempt 1 and its corresponding attempt 2. This allows the Setup Ruby retry pattern to include a 60-second pause before the second attempt without breaking the CI contract test.
1 parent 40c541f commit 667cfb5

1 file changed

Lines changed: 6 additions & 1 deletion

File tree

‎scripts/tests/test_merge_queue_fail_fast.py‎

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -131,7 +131,12 @@ def test_no_job_tolerates_failure(self):
131131
continue
132132
self.assertRegex(step, r"^name: .* \(attempt 1\)\n", step[:80])
133133
sid = re.search(r"(?m)^ id: (\S+)$", step).group(1)
134-
retry = steps[i + 1]
134+
# Allow an optional pause step before attempt 2.
135+
next_step = steps[i + 1]
136+
if re.search(r"^name: .* \(pause before attempt 2\)\n", next_step):
137+
retry = steps[i + 2]
138+
else:
139+
retry = next_step
135140
self.assertRegex(retry, r"^name: .* \(attempt 2\)\n", retry[:80])
136141
self.assertIn(f"steps.{sid}.outcome != 'success'", retry, retry[:80])
137142
self.assertEqual(

0 commit comments

Comments
 (0)