2 # Copyright 2017 gRPC authors.
4 # Licensed under the Apache License, Version 2.0 (the "License");
5 # you may not use this file except in compliance with the License.
6 # You may obtain a copy of the License at
8 # http://www.apache.org/licenses/LICENSE-2.0
10 # Unless required by applicable law or agreed to in writing, software
11 # distributed under the License is distributed on an "AS IS" BASIS,
12 # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 # See the License for the specific language governing permissions and
14 # limitations under the License.
18 # change to grpc repo root
19 cd $(dirname $0)/../../..
21 source tools/internal_ci/helper_scripts/prepare_build_linux_rc
23 # make sure bazel is available
26 # to get "bazel" link for kokoro build, we need to generate
27 # invocation UUID, set a flag for bazel to use it
28 # and upload "bazel_invocation_ids" file as artifact.
29 BAZEL_INVOCATION_ID="$(uuidgen)"
30 echo "${BAZEL_INVOCATION_ID}" >"${KOKORO_ARTIFACTS_DIR}/bazel_invocation_ids"
33 --bazelrc=tools/remote_build/kokoro.bazelrc \
35 --invocation_id="${BAZEL_INVOCATION_ID}" \
36 --workspace_status_command=tools/remote_build/workspace_status_kokoro.sh \
38 -- //test/... || FAILED="true"
40 if [ "$UPLOAD_TEST_RESULTS" != "" ]
42 # Sleep to let ResultStore finish writing results before querying
44 python ./tools/run_tests/python_utils/upload_rbe_results.py
47 if [ "$FAILED" != "" ]