1#!/bin/bash 2set -eux 3 4cd git/re2 5 6case "${KOKORO_JOB_NAME}" in 7 */windows-*) 8 choco upgrade bazel -y -i 9 # Pin to Visual Studio 2015, which is the minimum that we support. 10 export BAZEL_VC='C:\Program Files (x86)\Microsoft Visual Studio 14.0\VC' 11 ;; 12 *) 13 # Use the script provided by Kokoro. 14 use_bazel.sh latest 15 ;; 16esac 17 18bazel clean 19bazel build --compilation_mode=dbg -- //:all 20bazel test --compilation_mode=dbg --test_output=errors -- //:all \ 21 -//:dfa_test \ 22 -//:exhaustive1_test \ 23 -//:exhaustive2_test \ 24 -//:exhaustive3_test \ 25 -//:exhaustive_test \ 26 -//:random_test 27 28bazel clean 29bazel build --compilation_mode=opt -- //:all 30bazel test --compilation_mode=opt --test_output=errors -- //:all \ 31 -//:dfa_test \ 32 -//:exhaustive1_test \ 33 -//:exhaustive2_test \ 34 -//:exhaustive3_test \ 35 -//:exhaustive_test \ 36 -//:random_test 37 38exit 0 39