Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
22 changes: 15 additions & 7 deletions .github/workflows/maven_test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,30 +11,38 @@ concurrency:

jobs:
test:
name: Test
name: Test (JDK ${{ matrix.java }})
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
# 17 is the lowest JDK that can build this project: the Jackson 3
# dependency requires a Java 17 baseline and the multi-release build has
# a `release 17` compile execution. The Java 8 *target* stays covered by
# `<release>${java.version}</release>` on the default-compile execution.
java: [ 17, 21, 25 ]
steps:
- uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
with:
fetch-depth: 0
- name: Set up JDK 17
- name: Set up JDK ${{ matrix.java }}
uses: actions/setup-java@03ad4de0992f5dab5e18fcb136590ce7c4a0ac95 # v5.6.0
with:
java-version: 17
java-version: ${{ matrix.java }}
distribution: 'temurin'
- name: Cache and restore Maven packages on master
uses: actions/cache@55cc8345863c7cc4c66a329aec7e433d2d1c52a9 # v6.1.0
if: ${{ github.ref_name == 'master' }}
with:
path: ~/.m2
key: ${{ runner.os }}-m2-${{ hashFiles('**/pom.xml') }}
restore-keys: ${{ runner.os }}-m2
key: ${{ runner.os }}-m2-jdk${{ matrix.java }}-${{ hashFiles('**/pom.xml') }}
restore-keys: ${{ runner.os }}-m2-jdk${{ matrix.java }}
- name: Restore Maven packages on PR
uses: actions/cache/restore@55cc8345863c7cc4c66a329aec7e433d2d1c52a9 # v6.1.0
if: ${{ github.ref_name != 'master' }}
with:
path: ~/.m2
key: ${{ runner.os }}-m2-${{ hashFiles('**/pom.xml') }}
restore-keys: ${{ runner.os }}-m2
key: ${{ runner.os }}-m2-jdk${{ matrix.java }}-${{ hashFiles('**/pom.xml') }}
restore-keys: ${{ runner.os }}-m2-jdk${{ matrix.java }}
- name: Build and Test
run: ./mvnw clean verify -P integration-test