Skip to content

Commit

Permalink
testing: fix gotestsum install (algorand#2328)
Browse files Browse the repository at this point in the history
testing: fix gotestsum install

avoid installing swagger when not needed.
  • Loading branch information
winder authored Jun 24, 2021
1 parent 798c612 commit 90edab3
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 2 deletions.
8 changes: 7 additions & 1 deletion scripts/buildtools/install_buildtools.sh
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,12 @@ while getopts ":o:h" opt; do
done
shift $((OPTIND -1))

if [ "$#" -ne 0 ]; then
echo "Unexpected positional arguments passed to script: $@"
exit 1
fi


SCRIPTPATH="$( cd "$(dirname "$0")" ; pwd -P )"
pushd .
cd ${SCRIPTPATH}
Expand Down Expand Up @@ -76,7 +82,7 @@ function install_go_module {

if [[ "${BUILDTOOLS_INSTALL}" != "ALL" ]]; then
install_go_module "${BUILDTOOLS_INSTALL}"
return
exit 0
fi

install_go_module golang.org/x/lint golang.org/x/lint/golint
Expand Down
2 changes: 1 addition & 1 deletion scripts/travis/test.sh
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ chmod +x ~/gimme
eval "$(~/gimme "${GOLANG_VERSION}")"

# If this command fails the Makefile will select 'go test' instead.
"${SCRIPTPATH}/../buildtools/install_buildtools.sh" "gotest.tools/gotestsum" || true
"${SCRIPTPATH}/../buildtools/install_buildtools.sh" -o "gotest.tools/gotestsum" || true

if [ "${OS}-${ARCH}" = "linux-arm" ] || [ "${OS}-${ARCH}" = "windows-amd64" ]; then
# for arm, no tests need to be invoked.
Expand Down

0 comments on commit 90edab3

Please sign in to comment.