forked from AY2526S1-CS2103T-F11-2/tp
-
Notifications
You must be signed in to change notification settings - Fork 0
31 lines (24 loc) · 791 Bytes
/
Copy pathcodecov.yml
File metadata and controls
31 lines (24 loc) · 791 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
name: Build and Test (Gradle with Codecov)
on:
push:
pull_request:
jobs:
build:
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v4
- name: Set up Java
uses: actions/setup-java@v4
with:
distribution: 'temurin'
java-version: '17' # change this if you use a different Java version
- name: Grant execute permission for Gradle wrapper
run: chmod +x gradlew
- name: Build and run tests
run: ./gradlew build jacocoTestReport
- name: Upload coverage to Codecov
uses: codecov/codecov-action@v4
with:
files: ./build/reports/jacoco/test/jacocoTestReport.xml
token: ${{ secrets.CODECOV_TOKEN }} # only needed for private repos