From 963e384b254056b6879744ba0b5d69fc0699f0bf Mon Sep 17 00:00:00 2001 From: Mridula <66699525+mpeddada1@users.noreply.github.com> Date: Tue, 14 Jun 2022 14:44:02 -0400 Subject: [PATCH] fix: add build script for JDK 17 native image testing (#965) * fix: add build script for JDK 17 native image testing --- .kokoro/build.sh | 5 +++++ .kokoro/presubmit/graalvm-native-17.cfg | 27 +++++++++++++++++++++++++ owlbot.py | 3 ++- 3 files changed, 34 insertions(+), 1 deletion(-) create mode 100644 .kokoro/presubmit/graalvm-native-17.cfg diff --git a/.kokoro/build.sh b/.kokoro/build.sh index d4f07415d..c1c6a48ff 100755 --- a/.kokoro/build.sh +++ b/.kokoro/build.sh @@ -74,6 +74,11 @@ graalvm) mvn -B ${INTEGRATION_TEST_ARGS} -ntp -Pnative -Penable-integration-tests test RETURN_CODE=$? ;; +graalvm17) + # Run Unit and Integration Tests with Native Image + mvn -B ${INTEGRATION_TEST_ARGS} -ntp -Pnative -Penable-integration-tests test + RETURN_CODE=$? + ;; samples) SAMPLES_DIR=samples # only run ITs in snapshot/ on presubmit PRs. run ITs in all 3 samples/ subdirectories otherwise. diff --git a/.kokoro/presubmit/graalvm-native-17.cfg b/.kokoro/presubmit/graalvm-native-17.cfg new file mode 100644 index 000000000..833f9269b --- /dev/null +++ b/.kokoro/presubmit/graalvm-native-17.cfg @@ -0,0 +1,27 @@ +# Format: //devtools/kokoro/config/proto/build.proto + +# Configure the docker image for kokoro-trampoline. +env_vars: { + key: "TRAMPOLINE_IMAGE" + value: "gcr.io/cloud-devrel-kokoro-resources/graalvm17" +} + +env_vars: { + key: "JOB_TYPE" + value: "graalvm17" +} + +env_vars: { + key: "GCLOUD_PROJECT" + value: "java-review" +} + +env_vars: { + key: "GOOGLE_APPLICATION_CREDENTIALS" + value: "secret_manager/java-review_firestore-java-it" +} + +env_vars: { + key: "SECRET_MANAGER_KEYS" + value: "java-review_firestore-java-it" +} \ No newline at end of file diff --git a/owlbot.py b/owlbot.py index 37229a306..55984884f 100644 --- a/owlbot.py +++ b/owlbot.py @@ -83,5 +83,6 @@ '.kokoro/presubmit/samples.cfg', '.kokoro/nightly/integration.cfg', '.kokoro/nightly/java11-integration.cfg', - '.kokoro/nightly/samples.cfg' + '.kokoro/nightly/samples.cfg', + '.kokoro/build.sh' ]) \ No newline at end of file