v4.0.1 #103
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: flusmic | |
on: | |
push: | |
paths: | |
- "packages/flusmic/**" | |
- ".github/workflows/flusmic.yaml" | |
pull_request: | |
paths: | |
- "packages/flusmic/**" | |
- ".github/workflows/flusmic.yaml" | |
jobs: | |
flusmic-testing: | |
defaults: | |
run: | |
working-directory: packages/flusmic | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v2 | |
- uses: dart-lang/setup-dart@v1 | |
- name: Get dependencies | |
run: dart pub get | |
- name: Format code | |
run: dart format --set-exit-if-changed . | |
- name: Analyze code | |
run: dart analyze --fatal-infos --fatal-warnings . | |
- name: Testing | |
run: | | |
dart pub global activate coverage 1.6.1 | |
dart test --coverage=coverage && dart pub global run coverage:format_coverage --lcov --in=coverage --out=coverage/lcov.info --report-on=lib | |
- name: Check coverage percentage | |
uses: VeryGoodOpenSource/very_good_coverage@v1.2.0 | |
with: | |
path: "./packages/flusmic/coverage/lcov.info" | |
min_coverage: 95 | |
exclude: "**/*.g.dart **/*.freezed.dart example/**" | |
- name: upload coverage | |
uses: codecov/codecov-action@v1 | |
with: | |
token: ${{ secrets.CODE_COVERAGE }} | |
flusmic-score: | |
defaults: | |
run: | |
working-directory: packages/flusmic | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v2 | |
- uses: subosito/flutter-action@v1.5.3 | |
- name: Install dependencies | |
run: flutter packages get | |
- name: Install pana | |
run: flutter pub global activate pana | |
- name: Check score | |
run: | | |
chmod +x ../../scripts/score.sh | |
../../scripts/score.sh 110 | |
shell: bash |