Analyze & Test #1
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: Analyze & Test | |
on: | |
pull_request: | |
workflow_dispatch: | |
jobs: | |
analysis: | |
runs-on: ubuntu-latest | |
steps: | |
# Checkout the repository | |
- uses: actions/checkout@v3 | |
# Setup Flutter environment | |
- uses: subosito/flutter-action@v2 | |
with: | |
channel: "stable" | |
# Download all the packages that the app uses | |
- run: flutter pub get | |
# Run all tests | |
- run: flutter analyze | |
test_goldens: | |
runs-on: ubuntu-latest | |
steps: | |
# Checkout the repository | |
- uses: actions/checkout@v3 | |
# Setup Flutter environment | |
- uses: subosito/flutter-action@v2 | |
with: | |
channel: "stable" | |
# Download all the packages that the app uses | |
- run: flutter pub get | |
# Run all tests | |
- run: flutter test test_goldens | |
# Archive golden failures | |
- uses: actions/upload-artifact@v4 | |
if: failure() | |
with: | |
name: golden-failures | |
path: "**/failures/**/*.png" |