From bd62f6d309e35648b4609f36c4118e14e864bcc9 Mon Sep 17 00:00:00 2001 From: piotruela Date: Wed, 9 Apr 2025 19:55:03 +0200 Subject: [PATCH 1/2] chore: Rebase tests branch to latest master --- packages/patrol_cli/pubspec.yaml | 4 ++-- scripts/flutter_test_repo_test.bat | 19 +++++++++++++++++++ scripts/flutter_test_repo_test.sh | 17 +++++++++++++++++ 3 files changed, 38 insertions(+), 2 deletions(-) create mode 100644 scripts/flutter_test_repo_test.bat create mode 100755 scripts/flutter_test_repo_test.sh diff --git a/packages/patrol_cli/pubspec.yaml b/packages/patrol_cli/pubspec.yaml index e6324cbd5c..04e6be00aa 100644 --- a/packages/patrol_cli/pubspec.yaml +++ b/packages/patrol_cli/pubspec.yaml @@ -20,7 +20,7 @@ dependencies: args: ^2.4.2 ci: ^0.1.0 cli_completion: ^0.4.0 - collection: ^1.18.0 + collection: any coverage: ^1.9.0 dispose_scope: ^2.1.0 equatable: ^2.0.5 @@ -28,7 +28,7 @@ dependencies: glob: ^2.1.2 http: ^1.1.0 mason_logger: ^0.2.10 - meta: ^1.10.0 + meta: any package_config: ^2.1.1 path: ^1.8.3 patrol_log: ^0.7.1 diff --git a/scripts/flutter_test_repo_test.bat b/scripts/flutter_test_repo_test.bat new file mode 100644 index 0000000000..7b84afd495 --- /dev/null +++ b/scripts/flutter_test_repo_test.bat @@ -0,0 +1,19 @@ +@echo off + +set "root_dir=%CD%" + +for %%d in ( + "packages\patrol_finders" + "packages\patrol_cli" +) do ( + echo Processing %%d + cd "%%d" + + call flutter analyze --no-fatal-infos + if errorlevel 1 exit /b 1 + + call flutter test + if errorlevel 1 exit /b 1 + + cd "%root_dir%" +) diff --git a/scripts/flutter_test_repo_test.sh b/scripts/flutter_test_repo_test.sh new file mode 100755 index 0000000000..3efa0e963f --- /dev/null +++ b/scripts/flutter_test_repo_test.sh @@ -0,0 +1,17 @@ +#!/bin/bash +# Script invoked by the Flutter customer tests repository. + +set -e + +# Array of relative directories +dirs=("packages/patrol_finders" "packages/patrol_cli") + +# Loop through each directory +for dir in "${dirs[@]}"; do + cd "$dir" + + flutter analyze --no-fatal-infos + flutter test + + cd - > /dev/null # Return to the previous directory +done From e19cf0de7edd8303f6bd0d93df0a4349221b4b78 Mon Sep 17 00:00:00 2001 From: Kwiatek Szymon Date: Wed, 25 Mar 2026 12:10:08 +0100 Subject: [PATCH 2/2] Fix warning in test --- packages/patrol_cli/test/ios/ios_test_backend_test.dart | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/packages/patrol_cli/test/ios/ios_test_backend_test.dart b/packages/patrol_cli/test/ios/ios_test_backend_test.dart index 2127d3bf00..a6c4cc869c 100644 --- a/packages/patrol_cli/test/ios/ios_test_backend_test.dart +++ b/packages/patrol_cli/test/ios/ios_test_backend_test.dart @@ -74,13 +74,12 @@ void main() { }) { test(description, () async { final target = simulator ? 'iphonesimulator' : 'iphoneos'; - if (arch != null) { - arch = '-$arch'; - } + final archSuffix = arch != null ? '-$arch' : ''; final xcTestPlan = testPlan != null ? '-$testPlan' : ''; - final name = '${scheme}_$xcTestPlan${target}16.2$arch.xctestrun'; + final name = + '${scheme}_$xcTestPlan${target}16.2$archSuffix.xctestrun'; fs .file('build/ios_integ/Build/Products/$name')