-
Notifications
You must be signed in to change notification settings - Fork 2
41 lines (40 loc) · 1.27 KB
/
main.yml
File metadata and controls
41 lines (40 loc) · 1.27 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
#The name of your workflow.
name: build
# Trigger the workflow on push or pull request
on:
push:
branches: [main,dev]
pull_request:
branches: [main,dev]
#A workflow run is made up of one or more jobs. Jobs run in parallel by default.
jobs:
test:
#The type of machine to run the job on. [windows,macos, ubuntu , self-hosted]
defaults:
run:
working-directory: ./
runs-on: ubuntu-latest
#sequence of tasks called
steps:
# The branch or tag ref that triggered the workflow will be checked out.
# https://github.com/actions/checkout
- uses: actions/checkout@v3
# Setup a flutter environment.
# https://github.com/marketplace/actions/flutter-action
- uses: subosito/flutter-action@v2
with:
flutter-version: "3.3.2"
channel: "stable"
- run: flutter pub get
#- run: flutter analyze
# run flutter widgets tests and unit tests
- run: flutter test --coverage
- name: Check Code Coverage
uses: VeryGoodOpenSource/very_good_coverage@v1.1.1
with:
path: coverage/lcov.info
min_coverage: 80
- name: Upload coverage to Codecov
uses: codecov/codecov-action@v5.1.2
with:
token: ${{ secrets.CODECOV_TOKEN }}