-
-
Notifications
You must be signed in to change notification settings - Fork 3
55 lines (51 loc) · 1.4 KB
/
quality-monitor-build.yml
File metadata and controls
55 lines (51 loc) · 1.4 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
name: 'Quality Monitor'
on:
push:
branches:
- main
pull_request:
jobs:
build:
runs-on: [ubuntu-latest]
name: Create reports
steps:
- name: Checkout project
uses: actions/checkout@v6
- name: Set up JDK
uses: actions/setup-java@v5
with:
distribution: 'temurin'
java-version: 25
check-latest: true
cache: 'maven'
- name: Set up Maven
uses: stCarolas/setup-maven@v5
with:
maven-version: 3.9.12
- name: Check if quality monitor reports mutation coverage
run: |
FILE='.github/quality-monitor.json'
PATTERN='target/pit-reports/mutations.xml'
if [ -f "$FILE" ]; then
if grep -q "$PATTERN" "$FILE"; then
echo "PIT=-Ppit" >> "$GITHUB_ENV"
fi
fi
- name: Build with Maven
env:
PIT: ${{ env.PIT }}
BROWSER: chrome-container
run: |
mvn -V --color always -ntp clean verify $PIT -Pci | tee maven.log
if [ "${PIPESTATUS[0]}" != "0" ]; then
exit 1;
fi
mv -fv maven.log target/maven.log
- name: Upload Quality Reports
uses: actions/upload-artifact@v7
with:
name: quality-reports
path: |
**/target/**/*.json
**/target/**/*.xml
**/target/**/*.log