Skip to content

Commit a61a512

Browse files
skyzhsunshowers
authored andcommitted
fix(runner): cancel retry if cancel signal is received
Signed-off-by: Alex Chi <[email protected]>
1 parent 3d52c02 commit a61a512

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

nextest-runner/src/runner.rs

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -291,7 +291,9 @@ impl<'a> TestRunnerInner<'a> {
291291
// The test succeeded.
292292
run_statuses.push(run_status);
293293
break;
294-
} else if attempt < total_attempts {
294+
} else if attempt < total_attempts
295+
&& !canceled_ref.load(Ordering::Acquire)
296+
{
295297
// Retry this test: send a retry event, then retry the loop.
296298
let _ = this_run_sender.send(InternalTestEvent::Retry {
297299
test_instance,

0 commit comments

Comments
 (0)