xtf-cz / xtf

MIT License
12 stars 55 forks source link

ClusterVersionOpenShiftBinaryPathResolverTest failing because of changed oc location #566

Closed simkam closed 5 months ago

simkam commented 6 months ago

It looks like nightly builds are no longer pushed to https://mirror.openshift.com/pub/openshift-v4/amd64/clients/ocp-dev-preview/. At least version 4.14.0-ec.1, that we use in test, is not there and resolver than fallbacks to stable stable channel which obviously is in ocp-dev-preview.

Error:  cz.xtf.core.openshift.ClusterVersionOpenShiftBinaryPathResolverTest.resolveTest(String, String, String)[3]  Time elapsed: 0.905 s  <<< ERROR!
java.lang.IllegalStateException: Failed to download and extract oc binary from https://mirror.openshift.com/pub/openshift-v4/amd64/clients/ocp-dev-preview/stable/openshift-client-linux.tar.gz
    at cz.xtf.core.openshift.ClusterVersionOpenShiftBinaryPathResolverTest.testDownloadedVersion(ClusterVersionOpenShiftBinaryPathResolverTest.java:68)
    at cz.xtf.core.openshift.ClusterVersionOpenShiftBinaryPathResolverTest.resolveTest(ClusterVersionOpenShiftBinaryPathResolverTest.java:50)
Caused by: java.io.FileNotFoundException: https://mirror.openshift.com/pub/openshift-v4/amd64/clients/ocp-dev-preview/stable/openshift-client-linux.tar.gz
    at cz.xtf.core.openshift.ClusterVersionOpenShiftBinaryPathResolverTest.testDownloadedVersion(ClusterVersionOpenShiftBinaryPathResolverTest.java:68)
    at cz.xtf.core.openshift.ClusterVersionOpenShiftBinaryPathResolverTest.resolveTest(ClusterVersionOpenShiftBinaryPathResolverTest.java:50)
simkam commented 6 months ago

It looks like currently ec builds are in candidates- folders (https://mirror.openshift.com/pub/openshift-v4/amd64/clients/ocp-dev-preview/candidate-4.16/) and nightly builds only in https://amd64.ocp.releases.ci.openshift.org/.

But nightly builds are archived and can be either extracted online with redirects or using oc adm release extract --tools registry.ci.openshift.org/ocp/release:4.16.0-0.nightly-2024-05-21-095216 (requires pull secret).

https://amd64.ocp.releases.ci.openshift.org/releasestream/4.16.0-0.nightly/release/4.16.0-0.nightly-2024-05-21-095216