-
Notifications
You must be signed in to change notification settings - Fork 99
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
add build actions for build and run tests on different jdk versions (#87
- Loading branch information
Showing
2 changed files
with
58 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,50 @@ | ||
name: Build and run tests | ||
|
||
on: | ||
push: | ||
pull_request: | ||
branches: | ||
- master | ||
|
||
permissions: | ||
contents: read | ||
checks: write | ||
pull-requests: write | ||
|
||
jobs: | ||
build: | ||
|
||
name: Build and run tests on JDK ${{ matrix.jdk }} | ||
|
||
runs-on: ubuntu-latest | ||
strategy: | ||
fail-fast: false | ||
matrix: | ||
jdk: [8, 11, 17, 19, 21] | ||
env: | ||
main_jdk: 8 | ||
|
||
steps: | ||
- uses: actions/checkout@v3 | ||
|
||
- name: Set up Java | ||
uses: actions/setup-java@v3 | ||
with: | ||
java-version: ${{ matrix.jdk }} | ||
distribution: 'zulu' | ||
- name: Setup dependencies | ||
if: startsWith(matrix.os, 'ubuntu') | ||
run: | | ||
sudo apt install gcc \ | ||
apt install libssl-dev \ | ||
apt install maven | ||
- name: Build and run tests | ||
run: mvn clean test -DargLine="-Dci=true" | ||
|
||
- name: Publish test results | ||
uses: EnricoMi/publish-unit-test-result-action@v2 | ||
if: always() | ||
with: | ||
files: "target/surefire-reports/*.xml" | ||
check_name: "Test results on JDK ${{ matrix.jdk }}" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters