diff --git a/api/testtriggers/v1/testtrigger_types.go b/api/testtriggers/v1/testtrigger_types.go index bdb47b87..e346c655 100644 --- a/api/testtriggers/v1/testtrigger_types.go +++ b/api/testtriggers/v1/testtrigger_types.go @@ -84,7 +84,7 @@ const ( ) // TestTriggerEvent defines event for test triggers -// +kubebuilder:validation:Enum=created;modified;deleted;deployment-scale-update;deployment-image-update;deployment-env-update;deployment-containers-modified;event-start-test;event-end-test-success;event-end-test-failed;event-end-test-aborted;event-end-test-timeout;event-start-testsuite;event-end-testsuite-success;event-end-testsuite-failed;event-end-testsuite-aborted;event-end-testsuite-timeout;event-queue-testworkflow;event-start-testworkflow;event-end-testworkflow-success;event-end-testworkflow-failed;event-end-testworkflow-aborted;event-created;event-updated;event-deleted +// +kubebuilder:validation:Enum=created;modified;deleted;deployment-scale-update;deployment-image-update;deployment-env-update;deployment-containers-modified;deployment-generation-modified;deployment-resource-modified;event-start-test;event-end-test-success;event-end-test-failed;event-end-test-aborted;event-end-test-timeout;event-start-testsuite;event-end-testsuite-success;event-end-testsuite-failed;event-end-testsuite-aborted;event-end-testsuite-timeout;event-queue-testworkflow;event-start-testworkflow;event-end-testworkflow-success;event-end-testworkflow-failed;event-end-testworkflow-aborted;event-created;event-updated;event-deleted type TestTriggerEvent string // List of TestTriggerEvents @@ -96,6 +96,8 @@ const ( TestTriggerCauseDeploymentImageUpdate TestTriggerEvent = "deployment-image-update" TestTriggerCauseDeploymentEnvUpdate TestTriggerEvent = "deployment-env-update" TestTriggerCauseDeploymentContainersModified TestTriggerEvent = "deployment-containers-modified" + TestTriggerCauseDeploymentGenerationModified TestTriggerEvent = "deployment-generation-modified" + TestTriggerCauseDeploymentResourceModified TestTriggerEvent = "deployment-resource-modified" TestTriggerCauseEventStartTest TestTriggerEvent = "event-start-test" TestTriggerCauseEventEndTestSuccess TestTriggerEvent = "event-end-test-success" TestTriggerCauseEventEndTestFailed TestTriggerEvent = "event-end-test-failed" diff --git a/config/crd/bases/tests.testkube.io_testtriggers.yaml b/config/crd/bases/tests.testkube.io_testtriggers.yaml index 574fff55..05a9a28b 100644 --- a/config/crd/bases/tests.testkube.io_testtriggers.yaml +++ b/config/crd/bases/tests.testkube.io_testtriggers.yaml @@ -128,6 +128,8 @@ spec: - deployment-image-update - deployment-env-update - deployment-containers-modified + - deployment-generation-modified + - deployment-resource-modified - event-start-test - event-end-test-success - event-end-test-failed diff --git a/pkg/validation/tests/v1/testtrigger/types.go b/pkg/validation/tests/v1/testtrigger/types.go index 3339a38b..156e2b3e 100644 --- a/pkg/validation/tests/v1/testtrigger/types.go +++ b/pkg/validation/tests/v1/testtrigger/types.go @@ -28,6 +28,8 @@ const ( CauseDeploymentImageUpdate Cause = "deployment-image-update" CauseDeploymentEnvUpdate Cause = "deployment-env-update" CauseDeploymentContainersModified Cause = "deployment-containers-modified" + CauseDeploymentGenerationModified Cause = "deployment-generation-modified" + CauseDeploymentResourceModified Cause = "deployment-resource-modified" CauseEventStartTest Cause = "event-start-test" CauseEventEndTestSuccess Cause = "event-end-test-success" CauseEventEndTestFailed Cause = "event-end-test-failed"