From 47b699f70683916662103e61c8fc8d9180f5b2dc Mon Sep 17 00:00:00 2001 From: Jan Safranek Date: Tue, 5 May 2026 13:45:06 +0200 Subject: [PATCH] Tolerate events during the vSphere CSI driver removal test Test "vSphere CSI Driver Operator Removal" un-installs the CSI driver + installs it back. I.e. a DaemonSet and two Deployment with many events like "Created pod: vmware-vsphere-csi-driver-node-tkl25" --- .../duplicated_event_patterns.go | 19 +++++++++++++++++-- 1 file changed, 17 insertions(+), 2 deletions(-) diff --git a/pkg/monitortestlibrary/pathologicaleventlibrary/duplicated_event_patterns.go b/pkg/monitortestlibrary/pathologicaleventlibrary/duplicated_event_patterns.go index 6582828912f7..2999b68f18fd 100644 --- a/pkg/monitortestlibrary/pathologicaleventlibrary/duplicated_event_patterns.go +++ b/pkg/monitortestlibrary/pathologicaleventlibrary/duplicated_event_patterns.go @@ -1091,8 +1091,23 @@ func newTopologyAwareHintsDisabledDuringTaintTestsPathologicalEventMatcher(final // The tests change clusterCSIDriver object and have to rollout new pods to load new configuration. func newVsphereConfigurationTestsRollOutTooOftenEventMatcher(finalIntervals monitorapi.Intervals) EventMatcher { configurationTestIntervals := finalIntervals.Filter(func(eventInterval monitorapi.Interval) bool { - return eventInterval.Source == monitorapi.SourceE2ETest && - strings.Contains(eventInterval.Locator.Keys[monitorapi.LocatorE2ETestKey], "snapshot options in clusterCSIDriver") + if eventInterval.Source != monitorapi.SourceE2ETest { + return false + } + testNames := []string{ + // Snapshot configuration changes result in the DaemonSet + Deployment update + rollout, + // which generates a lot of "Create / Update / Delete" events. + "snapshot options in clusterCSIDriver", + // vSphere CSI driver removal test results in the DaemonSet + Deployment removal + re-creation, + // with a subsequent rollout. + "vSphere CSI Driver Operator Removal", + } + for _, testName := range testNames { + if strings.Contains(eventInterval.Locator.Keys[monitorapi.LocatorE2ETestKey], testName) { + return true + } + } + return false }) for i := range configurationTestIntervals { configurationTestIntervals[i].To = configurationTestIntervals[i].To.Add(time.Minute * 10)