mirror of https://github.com/linkerd/linkerd2.git
Fix upgrade integration test (#4744)
An unappropriate variable reuse resulted in the failure of the test for upgrading using manifests. This only happened when the upgrade was retried a second time (when there's a discrepancy in the heartbeat cron schedule, which is bening).
This commit is contained in:
parent
212c51acfb
commit
e225c46484
|
@ -242,13 +242,13 @@ func TestInstallOrUpgradeCli(t *testing.T) {
|
|||
// test `linkerd upgrade --from-manifests`
|
||||
if TestHelper.UpgradeFromVersion() != "" {
|
||||
resources := []string{"configmaps/" + k8s.ConfigConfigMapName, "configmaps/" + k8s.AddOnsConfigMapName, "secrets/" + k8s.IdentityIssuerSecretName}
|
||||
args := append([]string{"--namespace", TestHelper.GetLinkerdNamespace(), "get"}, resources...)
|
||||
args = append(args, "-oyaml")
|
||||
kubeArgs := append([]string{"--namespace", TestHelper.GetLinkerdNamespace(), "get"}, resources...)
|
||||
kubeArgs = append(kubeArgs, "-oyaml")
|
||||
|
||||
manifests, err := TestHelper.Kubectl("", args...)
|
||||
manifests, err := TestHelper.Kubectl("", kubeArgs...)
|
||||
if err != nil {
|
||||
testutil.AnnotatedFatalf(t, "'kubectl get' command failed",
|
||||
"'kubectl get' command failed with %s\n%s\n%s", err, manifests, args)
|
||||
"'kubectl get' command failed with %s\n%s\n%s", err, manifests, kubeArgs)
|
||||
}
|
||||
|
||||
exec = append(exec, "--from-manifests", "-")
|
||||
|
|
Loading…
Reference in New Issue