Skip to content

Commit 78ac50f

Browse files
committed
test/extended/cli/adm_upgrade/recommend: Allow Failing!=False
A depressing amount of the time in single-node testing, the authentication ClusterOperator is Available=False, and causes the 'recommend' command to error if the 'Failing' risk is not accepted. For example, in this aggregation run's 20 attempts [1]: * 9 passed. * three failed the '--version' test-case on 'authentication' 'Available=False' [2,3,4]. * two failed on build-cluster registry 500s [5,6]. * two failed on 'prometheus-operator' watch requests [7,8]. * one failed on a 'context deadline exceeded' out of 'runUpdateService' [9], with 'Failed to pull image...authentication required' issues trying to get the 'tools' image. * one failed on authentication Pod restarts [10]. * one failed on an un-excepted 'authentication' 'Available=False' ('OAuthServerDeployment_NoPod') [11]. * one failed on an unexpected successful return in an TestImageStreamTagsAdmission test-case [12]. So the auth functionality is pretty flaky in these single-node clusters under serial-suite load. Ideally [13] can get addressed or the auth component can otherwise get firmed up, but until then, this commit softens our logic to allow that kind of ClusterOperator Available=False (which gets bubbled up as ClusterVersion Failing=True), without failing our new test-case. [1]: #30113 (comment) [2]: https://prow.ci.openshift.org/view/gs/test-platform-results/logs/openshift-origin-30113-nightly-4.21-e2e-aws-ovn-single-node-serial/1964055948225941504 [3]: https://prow.ci.openshift.org/view/gs/test-platform-results/logs/openshift-origin-30113-nightly-4.21-e2e-aws-ovn-single-node-serial/1964055951426195456 [4]: https://prow.ci.openshift.org/view/gs/test-platform-results/logs/openshift-origin-30113-nightly-4.21-e2e-aws-ovn-single-node-serial/1964055945973600256 [5]: https://prow.ci.openshift.org/view/gs/test-platform-results/logs/openshift-origin-30113-nightly-4.21-e2e-aws-ovn-single-node-serial/1964055945063436288#1:build-log.txt%3A32 [6]: https://prow.ci.openshift.org/view/gs/test-platform-results/logs/openshift-origin-30113-nightly-4.21-e2e-aws-ovn-single-node-serial/1964055945512226816#1:build-log.txt%3A43 [7]: https://prow.ci.openshift.org/view/gs/test-platform-results/logs/openshift-origin-30113-nightly-4.21-e2e-aws-ovn-single-node-serial/1964055950948044800 [8]: https://prow.ci.openshift.org/view/gs/test-platform-results/logs/openshift-origin-30113-nightly-4.21-e2e-aws-ovn-single-node-serial/1964055948683120640 [9]: https://prow.ci.openshift.org/view/gs/test-platform-results/logs/openshift-origin-30113-nightly-4.21-e2e-aws-ovn-single-node-serial/1964055952327970816 [10]: https://prow.ci.openshift.org/view/gs/test-platform-results/logs/openshift-origin-30113-nightly-4.21-e2e-aws-ovn-single-node-serial/1964055953233940480 [11]: https://prow.ci.openshift.org/view/gs/test-platform-results/logs/openshift-origin-30113-nightly-4.21-e2e-aws-ovn-single-node-serial/1964055947772956672 [12]: https://prow.ci.openshift.org/view/gs/test-platform-results/logs/openshift-origin-30113-nightly-4.21-e2e-aws-ovn-single-node-serial/1964055952797732864 [13]: https://issues.redhat.com/browse/OCPBUGS-20056
1 parent c68be5e commit 78ac50f

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

test/extended/cli/adm_upgrade/recommend.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -240,7 +240,7 @@ Updates to 4[.][0-9]*:
240240
o.Expect(oc.Run("config", "set-credentials").Args("test", "--token", token).Execute()).To(o.Succeed())
241241
o.Expect(oc.Run("config", "set-context").Args("--current", "--user", "test").Execute()).To(o.Succeed())
242242

243-
out, err := oc.Run("--certificate-authority", caBundleFilePath, "adm", "upgrade", "recommend", "--version", fmt.Sprintf("4.%d.0", currentVersion.Minor+1), "--accept", "ConditionalUpdateRisk").EnvVar("OC_ENABLE_CMD_UPGRADE_RECOMMEND", "true").EnvVar("OC_ENABLE_CMD_UPGRADE_RECOMMEND_PRECHECK", "true").EnvVar("OC_ENABLE_CMD_UPGRADE_RECOMMEND_ACCEPT", "true").Output()
243+
out, err := oc.Run("--certificate-authority", caBundleFilePath, "adm", "upgrade", "recommend", "--version", fmt.Sprintf("4.%d.0", currentVersion.Minor+1), "--accept", "ConditionalUpdateRisk,Failing").EnvVar("OC_ENABLE_CMD_UPGRADE_RECOMMEND", "true").EnvVar("OC_ENABLE_CMD_UPGRADE_RECOMMEND_PRECHECK", "true").EnvVar("OC_ENABLE_CMD_UPGRADE_RECOMMEND_ACCEPT", "true").Output()
244244

245245
o.Expect(err).NotTo(o.HaveOccurred())
246246
err = matchRegexp(out, `The following conditions found no cause for concern in updating this cluster to later releases.*
@@ -253,7 +253,7 @@ Image: example.com/test@sha256:ccccccccccccccccccccccccccccccccccccccccccccccccc
253253
Release URL: https://example.com/release/4[.][0-9]*[.]0
254254
Reason: accepted (TestRiskA|MultipleReasons) via ConditionalUpdateRisk
255255
Message: (?s:.*)This is a test risk[.] https://example.com/testRiskA
256-
Update to 4[.][0-9]*[.]0 has no known issues relevant to this cluster other than the accepted ConditionalUpdateRisk.`)
256+
Update to 4[.][0-9]*[.]0 has no known issues relevant to this cluster other than the accepted ConditionalUpdateRisk(|,Failing).`)
257257
o.Expect(err).NotTo(o.HaveOccurred())
258258
})
259259
})

0 commit comments

Comments
 (0)