Skip to content

GitHub Changes

GitHub Changes #30

Workflow file for this run

name: Java CI
on:
push:
branches: [main]
pull_request:
branches: [main]
jobs:
checkstyle:
name: Checkstyle
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v3
- name: Set up JDK 21
uses: actions/setup-java@v3
with:
distribution: 'temurin'
java-version: '21'
- name: Build with Maven
run: mvn clean install
- name: Run Checkstyle
run: mvn checkstyle:check
- name: Archive Checkstyle Reports
if: failure()
uses: actions/upload-artifact@v3
with:
name: checkstyle-reports
path: target/checkstyle-result.xml
unit-tests:
name: Unit Tests
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v3
- name: Set up JDK 21
uses: actions/setup-java@v3
with:
distribution: 'temurin'
java-version: '21'
- name: Build
run: mvn --batch-mode -DskipTests package
- name: Test
run: mvn --batch-mode -Dmaven.test.failure.ignore=true -X test
- name: Report
uses: dorny/test-reporter@v1
if: always()
with:
name: Maven Tests
path: target/surefire-reports/*.xml
reporter: java-junit
fail-on-error: true