forked from prometheus/client_java
-
Notifications
You must be signed in to change notification settings - Fork 0
35 lines (30 loc) · 1.08 KB
/
Copy pathmulti-version-test.yml
File metadata and controls
35 lines (30 loc) · 1.08 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
---
name: Java-Version Compatibility Tests
on: [pull_request]
permissions: {}
jobs:
compatibility-test:
name: Test on Java ${{ matrix.java }}
runs-on: ubuntu-24.04
strategy:
fail-fast: false
matrix:
java: [17, 21, 25]
steps:
- name: Check out
uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7
with:
persist-credentials: false
- name: Set up Java ${{ matrix.java }}
id: setup-java
uses: actions/setup-java@0f481fcb613427c0f801b606911222b5b6f3083a # v5
with:
distribution: "temurin"
java-version: ${{ matrix.java }}
- name: Cache local Maven repository
uses: actions/cache@55cc8345863c7cc4c66a329aec7e433d2d1c52a9 # v6.1.0
with:
path: ~/.m2/repository
key: ${{ runner.os }}-maven-java${{ matrix.java }}-${{ hashFiles('**/pom.xml') }}
- name: Build and test on Java ${{ matrix.java }}
run: ./mvnw clean install -Dtest.java.version=${{ matrix.java }} -Dcheckstyle.skip=true -Dwarnings=-nowarn -Dcoverage.skip=true