Merge pull request #4905 from eXist-db/dependabot/maven/org.apache.ma… #3175
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
name: Test & documentation | |
on: [push, pull_request] | |
permissions: | |
contents: read | |
env: | |
MAVEN_OPTS: -XX:StartFlightRecording=maxsize=5g,disk=true,dumponexit=true,settings=default,filename=./ -DtrimStackTrace=false -D'maven.resolver.transport=wagon' | |
DEV_JDK: '17' | |
jobs: | |
license: | |
name: License check | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v3 | |
- uses: actions/setup-java@v3 | |
with: | |
distribution: temurin | |
java-version: ${{ env.DEV_JDK }} | |
cache: 'maven' | |
- run: mvn -V -B license:check | |
timeout-minutes: 60 | |
dependencies: | |
name: Dependency checks | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v3 | |
- uses: actions/setup-java@v3 | |
with: | |
distribution: temurin | |
java-version: ${{ env.DEV_JDK }} | |
cache: 'maven' | |
- run: mvn -V -B dependency-check:check | |
timeout-minutes: 60 | |
documentation: | |
name: Javadoc | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v3 | |
- uses: actions/setup-java@v3 | |
with: | |
distribution: temurin | |
java-version: ${{ env.DEV_JDK }} | |
cache: 'maven' | |
- run: mvn -V -B -q -T 2C install javadoc:javadoc -DskipTests -D'dependency-check.skip' -D'license.skip' --projects '!exist-distribution,!exist-installer' --also-make | |
test: | |
name: (JDK ${{ matrix.jdk }} / ${{ matrix.os }}) Test | |
strategy: | |
fail-fast: false | |
matrix: | |
os: [ubuntu-latest, windows-latest, macOS-latest] | |
jdk: [ '17' ] | |
runs-on: ${{ matrix.os }} | |
steps: | |
- uses: actions/checkout@v3 | |
- name: Set up JDK ${{ matrix.jdk }} | |
uses: actions/setup-java@v3 | |
with: | |
distribution: temurin | |
java-version: ${{ matrix.jdk }} | |
cache: 'maven' | |
- name: Maven Test | |
timeout-minutes: 60 | |
run: mvn -V -B verify -D'dependency-check.skip' -D'license.skip' | |
- name: Maven Code Coverage | |
if: ${{ github.ref == 'refs/heads/develop' && matrix.jdk == env.DEV_JDK && matrix.os == 'ubuntu-latest' }} | |
env: | |
CI_NAME: github | |
BRANCH_NAME_OR_REF: ${{ github.head_ref || github.ref }} | |
CI_BUILD_NUMBER: ${{ github.run_id }} | |
CI_BUILD_URL: https://github.com/${{ github.repository }}/commit/${{ github.event.after }}/checks | |
COVERALLS_TOKEN: ${{ secrets.COVERALLS_TOKEN }} | |
run: mvn -V -B jacoco:report coveralls:report | |
- name: Archive build logs | |
if: always() | |
uses: actions/upload-artifact@v3 | |
with: | |
name: ${{ runner.os }}-jdk${{ matrix.jdk }}-build-logs | |
retention-days: 5 | |
path: | | |
**/*.jfr | |
**/hs_err_pid*.log | |
**/target/surefire-reports/* |