-
Notifications
You must be signed in to change notification settings - Fork 0
41 lines (40 loc) · 1.06 KB
/
dart.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
name: Dart CI
on:
push:
branches: [ main ]
pull_request:
branches: [ main ]
schedule:
- cron: "0 0 * * 0"
defaults:
run:
shell: bash
jobs:
build:
name: "Dart CI"
runs-on: ubuntu-latest
steps:
- uses: actions/cache@v3
with:
path: "~/.pub-cache/hosted"
key: "os:ubuntu-latest;pub-cache-hosted;dart:stable"
- uses: actions/checkout@v3
- uses: dart-lang/setup-dart@v1.3
with:
sdk: stable
- name: "Dependencies"
run: dart pub upgrade --no-precompile
- name: "Dart Analyzer"
run: dart analyze --fatal-infos .
- name: "Dart Formatter"
run: dart format --output=none --set-exit-if-changed .
- name: "VM Tests"
run: dart test --platform vm
- name: "Chrome Tests"
run: dart test --platform chrome
- name: "Collect coverage"
run: |
dart pub global activate coverage
dart pub global run coverage:test_with_coverage
- name: "Upload coverage"
uses: codecov/codecov-action@v3