File tree Expand file tree Collapse file tree 2 files changed +6
-3
lines changed
Expand file tree Collapse file tree 2 files changed +6
-3
lines changed Original file line number Diff line number Diff line change @@ -919,7 +919,7 @@ export function testBackend(options: TestBackendOptions): void {
919919 const updated =
920920 await backend . rescheduleWorkflowRunAfterFailedStepAttempt ( {
921921 workflowRunId : claimed . id ,
922- workerId : claimed . workerId ?? "" ,
922+ workerId : claimed . workerId ! , // eslint-disable-line @typescript-eslint/no-non-null-assertion
923923 error,
924924 availableAt,
925925 } ) ;
Original file line number Diff line number Diff line change @@ -610,21 +610,24 @@ function sleep(ms: number): Promise<void> {
610610function createMockStepAttempt (
611611 overrides : Partial < StepAttempt > = { } ,
612612) : StepAttempt {
613+ const status = overrides . status ?? "completed" ;
614+
613615 return {
614616 namespaceId : "default" ,
615617 id : "step-attempt-id" ,
616618 workflowRunId : "workflow-run-id" ,
617619 stepName : "step" ,
618620 kind : "function" ,
619- status : "completed" ,
621+ status,
620622 config : { } ,
621623 context : null ,
622624 output : null ,
623625 error : null ,
624626 childWorkflowRunNamespaceId : null ,
625627 childWorkflowRunId : null ,
626628 startedAt : new Date ( "2026-01-01T00:00:00.000Z" ) ,
627- finishedAt : new Date ( "2026-01-01T00:00:01.000Z" ) ,
629+ finishedAt :
630+ status === "running" ? null : new Date ( "2026-01-01T00:00:01.000Z" ) ,
628631 createdAt : new Date ( "2026-01-01T00:00:00.000Z" ) ,
629632 updatedAt : new Date ( "2026-01-01T00:00:01.000Z" ) ,
630633 ...overrides ,
You can’t perform that action at this time.
0 commit comments