Set JAVA_HOME for bazel_with_jdk_test

The local JDK is now the default --javabase and needs to be available for these
tests, see:
https://github.com/bazelbuild/bazel/commit/849df36c5ad31ebe8791c4228321c38c6d0ae56c

PiperOrigin-RevId: 196575260
diff --git a/src/test/shell/bazel/bazel_with_jdk_test.sh b/src/test/shell/bazel/bazel_with_jdk_test.sh
index d4a51f3..98c0223 100755
--- a/src/test/shell/bazel/bazel_with_jdk_test.sh
+++ b/src/test/shell/bazel/bazel_with_jdk_test.sh
@@ -38,6 +38,8 @@
   # actually using the bundled one. Remove it.
   fgrep -v -- "--host_javabase" "$TEST_TMPDIR/bazelrc" > "$TEST_TMPDIR/bazelrc.new"
   mv "$TEST_TMPDIR/bazelrc.new" "$TEST_TMPDIR/bazelrc"
+  # ... but ensure JAVA_HOME is set, so we can find a default --javabase
+  export JAVA_HOME="${bazel_javabase}"
 }
 
 function cleanup() {