File tree Expand file tree Collapse file tree 2 files changed +3
-5
lines changed Expand file tree Collapse file tree 2 files changed +3
-5
lines changed Original file line number Diff line number Diff line change @@ -96,8 +96,8 @@ type EventRef struct {
9696 // +kubebuilder:validation:Required
9797 TriggerEventRef string `json:"triggerEventRef" validate:"required"`
9898 // Reference to the unique name of a 'consumed' event definition
99- // +kubebuilder:validation:Required
100- ResultEventRef string `json:"resultEventRef" validate:"required" `
99+ // +optional
100+ ResultEventRef string `json:"resultEventRef"`
101101 // Maximum amount of time (ISO 8601 format) to wait for the result event. If not defined it be set to the
102102 // actionExecutionTimeout
103103 // +optional
Original file line number Diff line number Diff line change @@ -175,11 +175,9 @@ func TestEventRefStructLevelValidation(t *testing.T) {
175175 Model : func () Workflow {
176176 model := baseWorkflow .DeepCopy ()
177177 model .States [0 ].OperationState .Actions [0 ].EventRef .TriggerEventRef = ""
178- model .States [0 ].OperationState .Actions [0 ].EventRef .ResultEventRef = ""
179178 return * model
180179 },
181- Err : `workflow.states[0].actions[0].eventRef.triggerEventRef is required
182- workflow.states[0].actions[0].eventRef.resultEventRef is required` ,
180+ Err : `workflow.states[0].actions[0].eventRef.triggerEventRef is required` ,
183181 },
184182 {
185183 Desp : "exists" ,
You can’t perform that action at this time.
0 commit comments