File tree 2 files changed +3
-5
lines changed
2 files changed +3
-5
lines changed Original file line number Diff line number Diff line change @@ -96,8 +96,8 @@ type EventRef struct {
96
96
// +kubebuilder:validation:Required
97
97
TriggerEventRef string `json:"triggerEventRef" validate:"required"`
98
98
// 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"`
101
101
// Maximum amount of time (ISO 8601 format) to wait for the result event. If not defined it be set to the
102
102
// actionExecutionTimeout
103
103
// +optional
Original file line number Diff line number Diff line change @@ -175,11 +175,9 @@ func TestEventRefStructLevelValidation(t *testing.T) {
175
175
Model : func () Workflow {
176
176
model := baseWorkflow .DeepCopy ()
177
177
model .States [0 ].OperationState .Actions [0 ].EventRef .TriggerEventRef = ""
178
- model .States [0 ].OperationState .Actions [0 ].EventRef .ResultEventRef = ""
179
178
return * model
180
179
},
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` ,
183
181
},
184
182
{
185
183
Desp : "exists" ,
You can’t perform that action at this time.
0 commit comments