-
Notifications
You must be signed in to change notification settings - Fork 7
56 lines (49 loc) · 1.66 KB
/
build.yaml
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
on: [push, pull_request]
name: Build,Test
jobs:
build_test_ubuntu_macos:
name: Build number_inc_dec on stable
runs-on: ${{ matrix.os }}
strategy:
matrix:
os: [ubuntu-latest, macos-latest]
steps:
- uses: actions/checkout@v2
- uses: actions/setup-java@v1
with:
java-version: "12.x"
- uses: subosito/flutter-action@v1
with:
channel: "stable"
- name: Install dependencies
run: flutter pub get
- run: flutter test test/functionality_test.dart
# This separate build_test_windows is done because the golden files are created in windows
# Unfortunately these golden files differs in ubuntu & macos implementations and fails the golden tests.
# Also the code coverage is only updated here to include the golden tests.
build_test_windows:
name: Build number_inc_dec on stable
runs-on: windows-latest
steps:
- uses: actions/checkout@v2
- uses: actions/setup-java@v1
with:
java-version: "12.x"
- uses: subosito/flutter-action@v1
with:
channel: "stable"
# copied from @rrousselGit's river_pod workflow
- name: Install dependencies
run: flutter pub get
- name: Check format
run: dart format --set-exit-if-changed .
- name: Analyze
run: flutter analyze
working-directory: ${{ matrix.package }}
- name: Run tests
run: flutter test --coverage
working-directory: ${{ matrix.package }}
- name: Upload coverage to codecov
uses: codecov/codecov-action@v1
with:
token: ${{ secrets.CODECOV_TOKEN }}