-
Notifications
You must be signed in to change notification settings - Fork 4
33 lines (28 loc) · 835 Bytes
/
test.yml
File metadata and controls
33 lines (28 loc) · 835 Bytes
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
name: Publish Test Coverage Report
on:
push:
branches: [ "main" ]
pull_request:
branches: [ "main" ]
jobs:
publish-code-coverage-report:
name: JAVA
runs-on: ubuntu-latest
if: "! contains(toJSON(github.event.head_commit.message), 'skip ci')"
steps:
- name: Checkout Repository
uses: actions/checkout@v3
- name: Set up JDK 8
uses: actions/setup-java@v3
with:
java-version: '8'
distribution: 'temurin'
cache: maven
- name: Build and Run Tests with Coverage
run: mvn test
- name: SonarQube Scan
if: ${{ github.actor != 'dependabot[bot]' }}
uses: SonarSource/sonarqube-scan-action@v6.0.0
env:
SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }}
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}