Skip to content

Commit 6c118fe

Browse files
horitaku1124cplee
andauthored
#534 feat: step continues when continue-on-error is ture (#544)
* feat: step continues when continue-on-error is ture * fix: typo, logging and make bool continuable Co-authored-by: Casey Lee <[email protected]>
1 parent 14c06ee commit 6c118fe

File tree

1 file changed

+8
-1
lines changed

1 file changed

+8
-1
lines changed

pkg/runner/run_context.go

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -225,7 +225,14 @@ func (rc *RunContext) newStepExecutor(step *model.Step) common.Executor {
225225
common.Logger(ctx).Infof(" \u2705 Success - %s", sc.Step)
226226
} else {
227227
common.Logger(ctx).Errorf(" \u274C Failure - %s", sc.Step)
228-
rc.StepResults[rc.CurrentStep].Success = false
228+
229+
if sc.Step.ContinueOnError {
230+
common.Logger(ctx).Infof("Failed but continue next step")
231+
err = nil
232+
rc.StepResults[rc.CurrentStep].Success = true
233+
} else {
234+
rc.StepResults[rc.CurrentStep].Success = false
235+
}
229236
}
230237
return err
231238
}

0 commit comments

Comments
 (0)