-
Notifications
You must be signed in to change notification settings - Fork 0
58 lines (48 loc) · 1.47 KB
/
android.yml
File metadata and controls
58 lines (48 loc) · 1.47 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
55
56
57
58
name: Android CI
on:
push:
branches: [ "develop" ]
pull_request:
branches: [ "develop" ]
concurrency:
group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }}
cancel-in-progress: true
permissions:
contents: read
pull-requests: write
env:
MIN_COVERAGE_ALL: ${{ vars.MIN_COVERAGE_ALL || 65 }}
MIN_COVERAGE_CHANGED_FILE: ${{ vars.MIN_COVERAGE_CHANGED_FILE || 65 }}
jobs:
android-ci:
name: Lint & Coverage
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Setup JDK 17
uses: actions/setup-java@v4
with:
java-version: '17'
distribution: 'temurin'
cache: gradle
- name: Make gradlew executable
run: chmod +x gradlew
# Run detekt
- name: Run Detekt
run: ./gradlew detekt
# Run Kover Coverage
- name: Run Kover Coverage
run: ./gradlew app:koverXmlReportStagingDebug
# Post Coverage Comment only for PRs
- name: Post Coverage Comment
if: github.event_name == 'pull_request'
uses: mi-kas/kover-report@v1
with:
path: app/build/reports/kover/reportStagingDebug.xml
token: ${{ secrets.GITHUB_TOKEN }}
title: Code Coverage
update-comment: true
min-coverage-overall: ${{ env.MIN_COVERAGE_ALL }}
min-coverage-changed-files: ${{ env.MIN_COVERAGE_CHANGED_FILE }}
coverage-counter-type: LINE