From 0539a12f991c2e04ad4fc2e01ffda15d20f13639 Mon Sep 17 00:00:00 2001 From: zarzet <42882290+zarzet@users.noreply.github.com> Date: Sun, 18 Oct 2026 21:51:27 +0700 Subject: [PATCH] ci: add a dart format gate and fix the one drifted test file Format drift was unchecked in CI. Add the gate before analyze and include integration_test in the documented format commands. --- .github/PULL_REQUEST_TEMPLATE.md | 2 +- .github/workflows/ci.yml | 3 +++ CONTRIBUTING.md | 2 +- test/download_queue_codec_test.dart | 2 +- 4 files changed, 6 insertions(+), 3 deletions(-) diff --git a/.github/PULL_REQUEST_TEMPLATE.md b/.github/PULL_REQUEST_TEMPLATE.md index b7fa18c0..9fb53a74 100644 --- a/.github/PULL_REQUEST_TEMPLATE.md +++ b/.github/PULL_REQUEST_TEMPLATE.md @@ -19,7 +19,7 @@ -- [ ] `dart format --output=none --set-exit-if-changed lib test` +- [ ] `dart format --output=none --set-exit-if-changed lib test integration_test` - [ ] `flutter analyze` - [ ] `flutter test` - [ ] `bash scripts/check_rust_backend.sh` diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 37635ed7..0aaaf249 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -118,6 +118,9 @@ jobs: - name: Get Flutter dependencies run: flutter pub get + - name: Check formatting + run: dart format --output=none --set-exit-if-changed lib test integration_test + - name: Analyze run: flutter analyze diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index 15a38be7..b5a8a94b 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -167,7 +167,7 @@ that policy. Flutter and Dart: ```bash -fvm dart format --output=none --set-exit-if-changed lib test +fvm dart format --output=none --set-exit-if-changed lib test integration_test fvm flutter analyze fvm flutter test ``` diff --git a/test/download_queue_codec_test.dart b/test/download_queue_codec_test.dart index 6d4de2f3..cdad01c0 100644 --- a/test/download_queue_codec_test.dart +++ b/test/download_queue_codec_test.dart @@ -115,7 +115,7 @@ void main() { isA().having( (error) => error.toString(), 'message', - contains('_ThrowingTrack'), + contains('_ThrowingTrack'), ), ), );