Feature/deps #9
Workflow file for this run
This file contains hidden or 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: Tests | |
| on: | |
| push: | |
| branches: [ main, develop ] | |
| pull_request: | |
| branches: [ main, develop ] | |
| workflow_dispatch: | |
| jobs: | |
| test: | |
| runs-on: ${{ matrix.os }} | |
| strategy: | |
| fail-fast: false | |
| matrix: | |
| os: [ubuntu-latest, macos-latest, windows-latest] | |
| sdk: [stable, beta] | |
| steps: | |
| - name: Checkout code | |
| uses: actions/checkout@v4 | |
| - name: Setup Dart SDK | |
| uses: dart-lang/setup-dart@v1 | |
| with: | |
| sdk: ${{ matrix.sdk }} | |
| - name: Print Dart version | |
| run: dart --version | |
| - name: Install dependencies | |
| run: dart pub get | |
| - name: Verify formatting | |
| run: dart format --output=none --set-exit-if-changed . | |
| - name: Analyze code | |
| run: dart analyze --fatal-infos | |
| - name: Run tests | |
| run: dart test | |
| - name: Run tests with coverage | |
| if: matrix.os == 'ubuntu-latest' && matrix.sdk == 'stable' | |
| run: | | |
| dart pub global activate coverage | |
| dart pub global run coverage:test_with_coverage | |
| - name: Upload coverage to Codecov | |
| if: matrix.os == 'ubuntu-latest' && matrix.sdk == 'stable' | |
| uses: codecov/codecov-action@v4 | |
| with: | |
| file: ./coverage/lcov.info | |
| fail_ci_if_error: false |