Fix intermittent test failure

Start the informerFactory before WaitForCacheSync

Kubernetes-commit: b9cd017a2146996677aa28ec992f7ed796f88c9b
This commit is contained in:
Dan Millwood 2025-02-12 16:22:47 +00:00 committed by Kubernetes Publisher
parent 7db8aee1f8
commit 10c2760fab
1 changed files with 1 additions and 1 deletions

View File

@ -656,8 +656,8 @@ func TestDispatcher(t *testing.T) {
if err != nil {
t.Fatal(err)
}
informerFactory.WaitForCacheSync(ctx.Done())
informerFactory.Start(ctx.Done())
informerFactory.WaitForCacheSync(ctx.Done())
for i, h := range tc.policyHooks {
tc.policyHooks[i].ParamInformer = paramInformer
tc.policyHooks[i].ParamScope = testParamScope{}