Cleaned up pom, added simple quality test action on push usable for forks of the repo

This commit is contained in:
Jeroen Willemsen
2021-09-29 09:40:45 +02:00
committed by Nanne Baars
parent 0c285eef5b
commit 9403bbb851
6 changed files with 58 additions and 8 deletions

52
.github/workflows/quality_checks.yml vendored Normal file
View File

@ -0,0 +1,52 @@
name: "Testing and linting"
on:
push:
branches-ignore:
- master
- develop
- release/*
jobs:
install-notest:
runs-on: ubuntu-latest
name: "Package and linting"
steps:
- uses: actions/checkout@v2
- name: set up JDK 15
uses: actions/setup-java@v2
with:
distribution: 'zulu'
java-version: 15
architecture: x64
- name: Cache Maven packages
uses: actions/cache@v2.1.5
with:
path: ~/.m2
key: ubuntu-latest-m2-${{ hashFiles('**/pom.xml') }}
restore-keys: ubuntu-latest-m2
- name: Test with Maven
run: mvn clean install -DskipTests
testing:
needs: install-notest
runs-on: ubuntu-latest
strategy:
matrix:
args:
- mvn -pl '!webgoat-integration-tests' test
- mvn -pl webgoat-integration-tests test
steps:
- uses: actions/checkout@v2
- name: set up JDK 15
uses: actions/setup-java@v2
with:
distribution: 'zulu'
java-version: 15
architecture: x64
- name: Cache Maven packages
uses: actions/cache@v2.1.5
with:
path: ~/.m2
key: ubuntu-latest-m2-${{ hashFiles('**/pom.xml') }}
restore-keys: ubuntu-latest-m2
- name: Test with Maven
run: ${{ matrix.args }}