From a2d875f18ffe102c1d1e34cb2eda9850d720b5e7 Mon Sep 17 00:00:00 2001 From: Brenna N Epp Date: Fri, 20 Dec 2024 18:10:54 -0800 Subject: [PATCH] test(all): fix multiple files in significant changes in continuous tests `if [ -z $SIGNIFICANT_CHANGES ]; then` gets translated to for example: ``` + '[' -z storage/grpc_client.go storage/integration_test.go ']' ``` Which causes the error: ``` github/google-cloud-go/internal/kokoro/continuous.sh: line 162: [: storage/grpc_client.go: binary operator expected ``` --- internal/kokoro/continuous.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/internal/kokoro/continuous.sh b/internal/kokoro/continuous.sh index b870465ab086..2c9a8af0ed6f 100755 --- a/internal/kokoro/continuous.sh +++ b/internal/kokoro/continuous.sh @@ -159,7 +159,7 @@ if [[ $KOKORO_JOB_NAME == *"continuous"* ]]; then # Continuous jobs only run root tests & tests in submodules changed by the PR. SIGNIFICANT_CHANGES=$(git --no-pager diff --name-only $KOKORO_GIT_COMMIT^..$KOKORO_GIT_COMMIT | grep -Ev '(\.md$|^\.github|\.json$|\.yaml$)' || true) - if [ -z $SIGNIFICANT_CHANGES ]; then + if [[ -z $SIGNIFICANT_CHANGES ]]; then echo "No changes detected, skipping tests" exit 0 fi