diff --git a/test/e2e/steps/hooks.go b/test/e2e/steps/hooks.go index 556a99638..db86a6460 100644 --- a/test/e2e/steps/hooks.go +++ b/test/e2e/steps/hooks.go @@ -216,7 +216,7 @@ func ScenarioCleanup(ctx context.Context, _ *godog.Scenario, err error) (context if sc.clusterExtensionName != "" { forDeletion = append(forDeletion, resource{name: sc.clusterExtensionName, kind: "clusterextension"}) } - if sc.clusterObjectSetName != "" { + if sc.clusterObjectSetName != "" && featureGates[features.BoxcutterRuntime] { forDeletion = append(forDeletion, resource{name: sc.clusterObjectSetName, kind: "clusterobjectset"}) } forDeletion = append(forDeletion, resource{name: sc.namespace, kind: "namespace"})