test/integration: wait for convergence at end of impersonation test
Signed-off-by: Andrew Keesler <akeesler@vmware.com>
This commit is contained in:
parent
6154883855
commit
ebd5e45fa6
@ -156,7 +156,7 @@ func TestImpersonationProxy(t *testing.T) { //nolint:gocyclo // yeah, it's compl
|
|||||||
}
|
}
|
||||||
// At the end of the test, clean up the ConfigMap.
|
// At the end of the test, clean up the ConfigMap.
|
||||||
t.Cleanup(func() {
|
t.Cleanup(func() {
|
||||||
ctx, cancel = context.WithTimeout(context.Background(), time.Minute)
|
ctx, cancel = context.WithTimeout(context.Background(), 2*time.Minute)
|
||||||
defer cancel()
|
defer cancel()
|
||||||
|
|
||||||
// Delete any version that was created by this test.
|
// Delete any version that was created by this test.
|
||||||
@ -175,6 +175,14 @@ func TestImpersonationProxy(t *testing.T) { //nolint:gocyclo // yeah, it's compl
|
|||||||
_, err = adminClient.CoreV1().ConfigMaps(env.ConciergeNamespace).Create(ctx, oldConfigMap, metav1.CreateOptions{})
|
_, err = adminClient.CoreV1().ConfigMaps(env.ConciergeNamespace).Create(ctx, oldConfigMap, metav1.CreateOptions{})
|
||||||
require.NoError(t, err)
|
require.NoError(t, err)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// If we are running on an environment that has a load balancer, expect that the
|
||||||
|
// CredentialIssuer will be updated eventually with a successful impersonation proxy frontend.
|
||||||
|
// We do this to ensure that future tests that use the impersonation proxy (e.g.,
|
||||||
|
// TestE2EFullIntegration) will start with a known-good state.
|
||||||
|
if env.HasCapability(library.HasExternalLoadBalancerProvider) {
|
||||||
|
performImpersonatorDiscovery(ctx, t, env, adminConciergeClient)
|
||||||
|
}
|
||||||
})
|
})
|
||||||
|
|
||||||
if env.HasCapability(library.HasExternalLoadBalancerProvider) { //nolint:nestif // come on... it's just a test
|
if env.HasCapability(library.HasExternalLoadBalancerProvider) { //nolint:nestif // come on... it's just a test
|
||||||
|
Loading…
Reference in New Issue
Block a user