From 7b7df5e617ab75d3e5e43160bfc222ff427447dc Mon Sep 17 00:00:00 2001 From: Sam Rawlins Date: Tue, 30 Jun 2026 15:14:40 -0700 Subject: [PATCH] Check formatting in all packages and in tool/ --- tool/ci/bots.sh | 3 +-- tool/ci/package_tests.sh | 17 +++++++++++++++++ tool/ci/tool_tests.sh | 5 +++++ 3 files changed, 23 insertions(+), 2 deletions(-) diff --git a/tool/ci/bots.sh b/tool/ci/bots.sh index bd4a4b671b6..877c16a464b 100755 --- a/tool/ci/bots.sh +++ b/tool/ci/bots.sh @@ -15,9 +15,8 @@ echo `pwd` if [ "$BOT" = "main" ]; then - # Verify that dart format has been run. echo "Checking formatting..." - # Here, we use the dart instance from the flutter sdk. + # Here, we use the dart instance from the flutter SDK. $(dirname $(which flutter))/dart format --output=none --set-exit-if-changed . # Make sure the app versions are in sync. diff --git a/tool/ci/package_tests.sh b/tool/ci/package_tests.sh index 29e45671952..812ca1cebc3 100755 --- a/tool/ci/package_tests.sh +++ b/tool/ci/package_tests.sh @@ -13,6 +13,11 @@ if [ "$PACKAGE" = "devtools_app_shared" ]; then pushd $DEVTOOLS_DIR/packages/devtools_app_shared echo `pwd` + + echo "Checking formatting..." + # Here, we use the dart instance from the flutter SDK. + $(dirname $(which flutter))/dart format --output=none --set-exit-if-changed . + flutter test test/ popd @@ -20,6 +25,13 @@ elif [ "$PACKAGE" = "devtools_extensions" ]; then pushd $DEVTOOLS_DIR/packages/devtools_extensions echo `pwd` + + echo "Checking formatting..." + # Here, we use the dart instance from the flutter SDK. + $(dirname $(which flutter))/dart format --output=none --set-exit-if-changed . + + # Note that this will _not_ test any tests in nested directories, if we add + # any. flutter test test/*_test.dart # Skip this on Windows because `flutter test --platform chrome` # appears to hang there. @@ -33,6 +45,11 @@ elif [ "$PACKAGE" = "devtools_shared" ]; then pushd $DEVTOOLS_DIR/packages/devtools_shared echo `pwd` + + echo "Checking formatting..." + # Here, we use the dart instance from the flutter SDK. + $(dirname $(which flutter))/dart format --output=none --set-exit-if-changed . + dart test test/ popd diff --git a/tool/ci/tool_tests.sh b/tool/ci/tool_tests.sh index 58feb6ea690..63ac4e5839e 100755 --- a/tool/ci/tool_tests.sh +++ b/tool/ci/tool_tests.sh @@ -11,5 +11,10 @@ source ./tool/ci/setup.sh pushd $DEVTOOLS_DIR/tool echo `pwd` + +echo "Checking formatting..." +# Here, we use the dart instance from the flutter SDK. +$(dirname $(which flutter))/dart format --output=none --set-exit-if-changed lib/ test/ + flutter test test/ popd \ No newline at end of file