-
-
Notifications
You must be signed in to change notification settings - Fork 1
38 lines (34 loc) · 1.06 KB
/
codecov.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
name: Publish Dart to Codecov
on: [push]
jobs:
build:
strategy:
matrix:
os: [macos-latest, windows-latest, ubuntu-latest]
runs-on: ${{ matrix.os }}
steps:
- uses: actions/checkout@v3
- uses: actions/setup-java@v2
with:
distribution: 'zulu'
java-version: '17'
- uses: subosito/flutter-action@v2
with:
flutter-version: '3.10.6'
channel: 'stable'
# Get dependencies
- name: Install dependencies
run: dart pub get
# Run all tests with coverage
- name: Run tests with coverage
run: dart run test --coverage="coverage"
# Convert to LCOV
- name: Convert coverage to LCOV
run: dart run coverage:format_coverage --lcov --in=coverage --out=coverage.lcov --packages=.dart_tool/package_config.json --report-on=lib
# Upload coverage data
- name: Upload coverage to Codecov
uses: codecov/codecov-action@v3
env:
CODECOV_TOKEN: ${{secrets.CODECOV_TOKEN}}
with:
file: coverage.lcov