eksconfig_controller_reconciler_test: Eventually test for updated secret
Moves the check for the value of the modified secret into the
Eventually, since the new secret value is eventually consistent.
@@ -116,9 +116,8 @@ func TestEKSConfigReconciler(t *testing.T) {
Name: config.Name,
Namespace: "default",
}, secret)).To(Succeed())
- }).Should(Succeed())
-
g.Expect(string(secret.Data["value"])).To(Equal(string(oldUserData)))
+ }).Should(Succeed())
// Secret already exists in testEnv so we update it
config.Spec.KubeletExtraArgs = map[string]string{
@@ -140,8 +139,8 @@ func TestEKSConfigReconciler(t *testing.T) {
Name: config.Name,
Namespace: "default",
}, secret)).To(Succeed())
- }).Should(Succeed())
g.Expect(string(secret.Data["value"])).To(Equal(string(expectedUserData)))
+ }).Should(Succeed())
})
}
