34 lines
810 B
YAML
34 lines
810 B
YAML
name: dart-ci
|
|
|
|
on:
|
|
push:
|
|
branches: [ master ]
|
|
pull_request:
|
|
branches: [ master ]
|
|
|
|
jobs:
|
|
build:
|
|
runs-on: ubuntu-latest
|
|
|
|
steps:
|
|
- uses: actions/checkout@v2
|
|
- uses: dart-lang/setup-dart@v1
|
|
|
|
- name: Install dependencies
|
|
run: dart pub get
|
|
|
|
- name: Analyze project source
|
|
run: dart analyze
|
|
|
|
- name: Run tests and format coverage
|
|
run: |
|
|
dart test --coverage=coverage
|
|
dart run coverage:format_coverage --lcov --in=coverage \
|
|
-out=coverage/lcov.info --packages=.dart_tool/package_config.json --report-on=lib,bin
|
|
|
|
- uses: codecov/codecov-action@v2
|
|
name: Publish coverage to Codecov
|
|
with:
|
|
token: ${{secrets.CODECOV_TOKEN}}
|
|
fail_ci_if_error: true
|
|
verbose: false
|