Skip to content

Bump spring-security-config from 5.8.3 to 5.8.5 #96

Bump spring-security-config from 5.8.3 to 5.8.5

Bump spring-security-config from 5.8.3 to 5.8.5 #96

Workflow file for this run

name: CI
on:
push:
branches: ["main", "poc_pipeline"]
pull_request:
branches: ["main"]
workflow_dispatch:
env:
MAVEN_OPTS: "-Dhttps.protocols=TLSv1.2 -Dmaven.color=false"
MVN_CLI_ARGS: "--batch-mode --no-transfer-progress --fail-at-end --show-version"
jobs:
quality-checks:
name: Check ${{ matrix.tool.display_name }}
strategy:
fail-fast: false
matrix:
tool:
- {"mvn_goal": "net.revelc.code:impsort-maven-plugin:check", "display_name": "Import Sort"}
- {"mvn_goal": "net.revelc.code.formatter:formatter-maven-plugin:validate", "display_name": "Formatter"}
- {"mvn_goal": "org.apache.maven.plugins:maven-pmd-plugin:pmd", "display_name": "pmd"}
- {"mvn_goal": "org.apache.maven.plugins:maven-checkstyle-plugin:checkstyle", "display_name": "Checkstyle"}
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: Setup java
uses: actions/setup-java@v3
with:
distribution: "temurin"
java-version: "17"
cache: maven
- run: mvn $MVN_CLI_ARGS ${{ matrix.tool.mvn_goal }}
- name: Show pmd findings
if: ${{ contains(matrix.tool.mvn_goal, 'pmd') }}
run: python .pipeline/scripts/print-pmd.py
- name: Show Checkstyle findings
if: ${{ contains(matrix.tool.mvn_goal, 'checkstyle') }}
run: python .pipeline/scripts/print-checkstyle.py
build:
runs-on: ubuntu-latest
# Permissions block is optional, useful for dependabot checks
permissions:
checks: write
contents: read
strategy:
fail-fast: false
matrix:
# jdk 20 currently does not work because of a warning:
# Warning: source/target value 8 is obsolete and will be removed in a future release
java: [ '17', '19' ]
name: Build, Test and Verify JDK ${{ matrix.Java }}
steps:
- uses: actions/checkout@v3
- name: Setup java
uses: actions/setup-java@v3
with:
distribution: "temurin"
java-version: ${{ matrix.java }}
cache: maven
- name: Build with Maven
run: mvn $MVN_CLI_ARGS verify jacoco:report
- name: Archive compiled classes
uses: actions/upload-artifact@v3
with:
name: compiled-classes-jdk-${{ matrix.Java }}
path: |
**/target/**/*.class
retention-days: 1
- name: Archive target
uses: actions/upload-artifact@v3
with:
name: target-jdk-${{ matrix.Java }}
path: |
**/target/
retention-days: 1
quality-checks-compiled:
needs: build
name: Check ${{ matrix.tool.display_name }}
strategy:
fail-fast: false
matrix:
tool:
- {"mvn_goal": "com.github.spotbugs:spotbugs-maven-plugin:spotbugs", "display_name": "Spotbugs"}
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: Setup java
uses: actions/setup-java@v3
with:
distribution: "temurin"
java-version: "17"
cache: maven
- uses: actions/download-artifact@v3
with:
name: compiled-classes-jdk-17
- run: mvn $MVN_CLI_ARGS ${{ matrix.tool.mvn_goal }}
- name: Show Spotbugs findings
if: ${{ contains(matrix.tool.mvn_goal, 'spotbugs') }}
run: python .pipeline/scripts/print-spotbugs.py
code-quality:
needs: build
name: Code Coverage
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: Setup java
uses: actions/setup-java@v3
with:
distribution: "temurin"
java-version: "17"
cache: maven
- uses: actions/download-artifact@v3
with:
name: target-jdk-17
- name: Publish Test Report
if: success() || failure()
uses: scacap/action-surefire-report@v1
- name: Generate JaCoCo Badge
id: jacoco
uses: cicirello/jacoco-badge-generator@v2
with:
generate-branches-badge: true
jacoco-csv-file: "**/jacoco.csv"
- name: Test Coverage Percentage
run: |
echo "coverage = ${{ steps.jacoco.outputs.coverage }}"
echo "branch coverage = ${{ steps.jacoco.outputs.branches }}"