Skip to content

Commit

Permalink
chore: Update ci.yaml to setup Java 21 CI tests (#2299)
Browse files Browse the repository at this point in the history
* chore: Update ci.yaml to setup Java 21 unit testing
  • Loading branch information
ddixit14 committed Dec 26, 2023
1 parent 8822f3b commit 3d885ba
Show file tree
Hide file tree
Showing 2 changed files with 26 additions and 3 deletions.
3 changes: 2 additions & 1 deletion .bazeliskrc
@@ -1,2 +1,3 @@
# See https://github.com/bazelbuild/bazelisk
USE_BAZEL_VERSION=6.0.0
# As per b/302171264#comment5, 6.4.0 supports Java 21.
USE_BAZEL_VERSION=6.4.0
26 changes: 24 additions & 2 deletions .github/workflows/ci.yaml
Expand Up @@ -9,7 +9,7 @@ jobs:
runs-on: ubuntu-22.04
strategy:
matrix:
java: [ 11, 17 ]
java: [ 11, 17]
steps:
- uses: actions/checkout@v3
- uses: actions/setup-java@v3
Expand Down Expand Up @@ -48,7 +48,29 @@ jobs:
pushd /tmp/java-compute/google-cloud-compute-small-v1-java
./gradlew clean build publishToMavenLocal sourcesJar allJars
popd
build-java-21:
name: "build(21) except self-service clients"
# Support for Java 21 is available for all use cases except self-service clients.
runs-on: ubuntu-22.04
steps:
- uses: actions/checkout@v3
- uses: actions/setup-java@v3
with:
java-version: 21
distribution: temurin
cache: maven
- run: java -version
- name: Unit Tests
run: |
mvn test --batch-mode --no-transfer-progress -Dcheckstyle.skip \
-Dfmt.skip -DenableTestCoverage
- run: bazelisk version
- name: Install Maven modules
run: |
mvn install -B -ntp -DskipTests -Dclirr.skip -Dcheckstyle.skip
- name: Integration Tests
run: |
bazelisk --batch test //test/integration/...
build-java8-except-gapic-generator-java:
name: "build(8) except for gapic-generator-java"
runs-on: ubuntu-22.04
Expand Down

0 comments on commit 3d885ba

Please sign in to comment.