forked from answerdigital/AnswerKing-Java
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathbuild_integration_and_code_analysis.yml
More file actions
54 lines (45 loc) · 1.32 KB
/
build_integration_and_code_analysis.yml
File metadata and controls
54 lines (45 loc) · 1.32 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: Integration and code analysis
on:
workflow_dispatch: null
push:
branches:
- main
- master
- develop
- v1.1.0-preview.2
pull_request:
types: [opened, synchronize, reopened]
jobs:
Build-Test:
name: Integration Test
outputs:
job-status: ${{ job.status }}
runs-on: ubuntu-latest
permissions:
checks: write
steps:
- uses: actions/checkout@v3
- name: Set up JDK 17
uses: actions/setup-java@v3
with:
java-version: '17'
distribution: 'corretto'
cache: 'maven'
- name: Build with Maven
run: mvn install -DskipTests
- name: Run tests with Maven
run: mvn test
- name: Run code coverage report
run: mvn jacoco:report
- name: Run code coverage check
run: mvn clean verify
- name: Print contents of target directory
run: ls target -lt
- name: Publish test coverage results
id: jacoco_reporter
uses: PavanMudigonda/jacoco-reporter@v4.8
with:
coverage_results_path: 'target/site/jacoco/jacoco.xml'
coverage_report_title: 'Test coverage results'
coverage_report_name: 'Test coverage results'
github_token: ${{ secrets.GITHUB_TOKEN }}