Skip to content

Add CI workflow for Dart project testing and analysis (#19) #5

Add CI workflow for Dart project testing and analysis (#19)

Add CI workflow for Dart project testing and analysis (#19) #5

Workflow file for this run

name: CI
on:
push:
branches: [main, develop]
pull_request:
permissions:
contents: read
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
jobs:
analyze:
name: Analyze
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: dart-lang/setup-dart@v1
with:
sdk: stable
- run: dart pub get
- run: dart format --set-exit-if-changed .
- run: dart analyze --fatal-infos
test:
name: Test (Dart ${{ matrix.sdk }})
runs-on: ubuntu-latest
strategy:
matrix:
sdk: [stable, "3.10.7"]
fail-fast: false
steps:
- uses: actions/checkout@v4
- uses: dart-lang/setup-dart@v1
with:
sdk: ${{ matrix.sdk }}
- run: dart pub get
- run: dart test