-
Notifications
You must be signed in to change notification settings - Fork 5
82 lines (67 loc) · 2.21 KB
/
pull-request.yml
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
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
---
name: Build and Test
defaults:
run:
shell: bash
concurrency:
group: ${{ github.head_ref }}${{ github.ref }}
cancel-in-progress: true
env:
JAVA_VERSION: 17
NODEJS_VERSION: 16.17.0
ATALA_GITHUB_ACTOR: ${{ secrets.ATALA_GITHUB_ACTOR }}
ATALA_GITHUB_TOKEN: ${{ secrets.ATALA_GITHUB_TOKEN }}
on:
push:
branches:
- "main"
pull_request:
jobs:
build:
runs-on: ubuntu-latest
steps:
- name: Checkout the repo
uses: actions/checkout@v3
- name: Install Java ${{ env.JAVA_VERSION }}
uses: actions/setup-java@v3
with:
java-version: ${{ env.JAVA_VERSION }}
distribution: "zulu"
- name: Gradle Build Action
uses: gradle/gradle-build-action@v2
- name: Runner
run: echo ${{ runner.os }}
- name: Build for JS, Android, JVM
run: |
./gradlew build test koverXmlReport koverHtmlReport --stacktrace
- name: Coverage Report
uses: mi-kas/kover-report@v1
with:
path: ${{ github.workspace }}/atala-prism-sdk/build/reports/kover/report.xml
token: ${{ env.ATALA_GITHUB_TOKEN }}
title: Code Coverage
update-comment: true
# - name: Publish test results
# if: always()
# uses: EnricoMi/publish-unit-test-result-action@v2
# with:
# files: "${{ github.workspace }}/atala-prism-sdk/build/test-results/testReleaseUnitTest/TEST-*.xml"
# comment_title: "Unit Test Results"
# check_name: "Unit Test Results"
- name: Publish test results
if: always()
uses: EnricoMi/publish-unit-test-result-action/composite@v2
with:
files: "${{ github.workspace }}/atala-prism-sdk/build/test-results/testReleaseUnitTest/TEST-*.xml"
comment_title: "Unit Test Results"
check_name: "Unit Test Results"
- name: Upload Tests Reports
uses: actions/upload-artifact@v3
if: always()
with:
name: kover-html
path: |
atala-prism-sdk/build/kover/atala-prism-sdk/xml
atala-prism-sdk/build/reports/tests/**/*.html
atala-prism-sdk/build/reports/tests/jvmTest/index.html
if-no-files-found: error