Skip to content

Commit 69bd71e

Browse files
chore: add CSI_PROW_SIDECAR_E2E_PATH
adds CSI_PROW_SIDECAR_E2E_PATH, an alternative to CSI_PROW_SIDECAR_E2E_IMPORT_PATH that can be used if the go module referenced in the import path has a /v{x} suffix, making it differing from the directory of the module.
1 parent f40f0cc commit 69bd71e

File tree

1 file changed

+6
-3
lines changed

1 file changed

+6
-3
lines changed

prow.sh

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -231,8 +231,11 @@ configvar CSI_PROW_E2E_VERSION "$(version_to_git "${CSI_PROW_KUBERNETES_VERSION}
231231
configvar CSI_PROW_E2E_REPO "https://github.com/kubernetes/kubernetes" "E2E repo"
232232
configvar CSI_PROW_E2E_IMPORT_PATH "k8s.io/kubernetes" "E2E package"
233233

234-
# Local path for e2e tests. Set to "none" to disable.
235-
configvar CSI_PROW_SIDECAR_E2E_IMPORT_PATH "none" "CSI Sidecar E2E package"
234+
# Local path & package path for e2e tests. Set to "none" to disable.
235+
# When using versioned go modules, the import path is the module path whereas the path
236+
# should not contain the version and be the directory where the module is checked out.
237+
configvar CSI_PROW_SIDECAR_E2E_IMPORT_PATH "none" "CSI Sidecar E2E package (go import path)"
238+
configvar CSI_PROW_SIDECAR_E2E_PATH "${CSI_PROW_SIDECAR_E2E_IMPORT_PATH}" "CSI Sidecar E2E path (directory)"
236239

237240
# csi-sanity testing from the csi-test repo can be run against the installed
238241
# CSI driver. For this to work, deploying the driver must expose the Unix domain
@@ -1035,7 +1038,7 @@ run_e2e () (
10351038
trap move_junit EXIT
10361039
10371040
if [ "${name}" == "local" ]; then
1038-
cd "${GOPATH}/src/${CSI_PROW_SIDECAR_E2E_IMPORT_PATH}" &&
1041+
cd "${GOPATH}/src/${CSI_PROW_SIDECAR_E2E_PATH}" &&
10391042
run_with_loggers env KUBECONFIG="$KUBECONFIG" KUBE_TEST_REPO_LIST="$(if [ -e "${CSI_PROW_WORK}/e2e-repo-list" ]; then echo "${CSI_PROW_WORK}/e2e-repo-list"; fi)" ginkgo --timeout="${CSI_PROW_GINKGO_TIMEOUT}" -v "$@" "${CSI_PROW_WORK}/e2e-local.test" -- -report-dir "${ARTIFACTS}" -report-prefix local
10401043
else
10411044
cd "${GOPATH}/src/${CSI_PROW_E2E_IMPORT_PATH}" &&

0 commit comments

Comments
 (0)