tests: Use $HOME/go as fallback for $GOPATH

Considering that someone may want to run the tests locally, we shouldn't
rely on having GITHUB_WORKSPACE exported, and fallback to $HOME/go if
needed.

Signed-off-by: Fabiano Fidêncio <fabiano.fidencio@intel.com>
This commit is contained in:
Fabiano Fidêncio 2023-07-13 12:40:59 +02:00
parent b87ed27416
commit f3738beaca

View File

@ -335,8 +335,10 @@ function check_containerd_config_for_kata() {
} }
function ensure_yq() { function ensure_yq() {
: "${GOPATH:=${GITHUB_WORKSPACE}}" : "${GOPATH:=${GITHUB_WORKSPACE:-$HOME/go}}"
export GOPATH export GOPATH
export PATH="${GOPATH}/bin:${PATH}" export PATH="${GOPATH}/bin:${PATH}"
INSTALL_IN_GOPATH=true "${repo_root_dir}/ci/install_yq.sh" INSTALL_IN_GOPATH=true "${repo_root_dir}/ci/install_yq.sh"
} }