Skip to content

Commit

Permalink
Adding failstep and error code changes to master (#440)
Browse files Browse the repository at this point in the history
* feat(errorCode): Adding error code inside chaosresult (#436)

Signed-off-by: Shubham Chaudhary <shubham.chaudhary@harness.io>
  • Loading branch information
ispeakc0de committed Dec 15, 2022
1 parent d39bc1f commit f3873a0
Show file tree
Hide file tree
Showing 2 changed files with 31 additions and 3 deletions.
12 changes: 10 additions & 2 deletions api/litmuschaos/v1alpha1/chaosresult_types.go
Original file line number Diff line number Diff line change
Expand Up @@ -118,12 +118,20 @@ type TestStatus struct {
Phase ResultPhase `json:"phase"`
// Verdict defines whether an experiment result is pass or fail
Verdict ResultVerdict `json:"verdict"`
// FailStep defines step where the experiments fails
FailStep string `json:"failStep,omitempty"`
// FailureOutput defines failed step and errorCode, if experiment failed
FailureOutput *FailureOutput `json:"failureOutput,omitempty"`
// ProbeSuccessPercentage defines the score of the probes
ProbeSuccessPercentage string `json:"probeSuccessPercentage,omitempty"`
}

// FailureOutput defines failed step and error code
type FailureOutput struct {
// ErrorCode defines error code of the experiment
ErrorCode string `json:"errorCode,omitempty"`
// FailedStep defines step where the experiments failed
FailedStep string `json:"failedStep,omitempty"`
}

//+kubebuilder:object:root=true
//+kubebuilder:subresource:status
// +genclient
Expand Down
22 changes: 21 additions & 1 deletion api/litmuschaos/v1alpha1/zz_generated.deepcopy.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

0 comments on commit f3873a0

Please sign in to comment.