feat: add skipped status as step result (#950)
Github sets the outcome and conclusion to skipped and this PR does the same during the pipeline run for the StepResults in act. Co-authored-by: Björn Brauer <bjoern.brauer@new-work.se> Co-authored-by: Björn Brauer <bjoern.brauer@new-work.se>
This commit is contained in:
parent
edd0fb92a7
commit
2eda7c6037
|
@ -7,11 +7,13 @@ type stepStatus int
|
|||
const (
|
||||
StepStatusSuccess stepStatus = iota
|
||||
StepStatusFailure
|
||||
StepStatusSkipped
|
||||
)
|
||||
|
||||
var stepStatusStrings = [...]string{
|
||||
"success",
|
||||
"failure",
|
||||
"skipped",
|
||||
}
|
||||
|
||||
func (s stepStatus) MarshalText() ([]byte, error) {
|
||||
|
|
|
@ -326,6 +326,8 @@ func (rc *RunContext) newStepExecutor(step *model.Step) common.Executor {
|
|||
|
||||
if !runStep {
|
||||
log.Debugf("Skipping step '%s' due to '%s'", sc.Step.String(), sc.Step.If.Value)
|
||||
rc.StepResults[rc.CurrentStep].Conclusion = model.StepStatusSkipped
|
||||
rc.StepResults[rc.CurrentStep].Outcome = model.StepStatusSkipped
|
||||
return nil
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue