-
Notifications
You must be signed in to change notification settings - Fork 15
44 lines (35 loc) · 966 Bytes
/
main.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
name: CI
# Controls when the action will run.
on:
push:
branches: [main]
pull_request:
branches: [main]
# Allows you to run this workflow manually from the Actions tab
workflow_dispatch:
jobs:
build:
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
channel: [stable]
steps:
- uses: actions/checkout@v2
- uses: subosito/flutter-action@v1
with:
channel: ${{ matrix.channel }}
- name: Install Dependencies
run: flutter pub get
- name: Format
run: dart format -o none --set-exit-if-changed .
- name: Analyze
run: flutter analyze --no-pub
- name: Run Tests
run: flutter test --no-pub --coverage
- name: Upload coverage to Codecov
if: ${{ matrix.channel == 'stable' }}
uses: codecov/codecov-action@v1
with:
token: ${{ secrets.CODECOV_TOKEN }}
file: coverage/lcov.info