Add a post-submit test shard for flutter/plugins tests (#70887)
Adds a new Luci test shard that runs flutter/plugins tests.
For now only the analysis phase of the flutter/plugins test suite is executed.
Manual invocation on Luci completed successfully: https://luci-milo.appspot.com/raw/build/logs.chromium.org/flutter/led/amirha_google.com/3210bb2dac01fca71b7db04dda02fa6ccd4df025afd55abea1970d26087d4962/+/annotations
diff --git a/dev/bots/test.dart b/dev/bots/test.dart
index 2aca003..c0c732d 100644
--- a/dev/bots/test.dart
+++ b/dev/bots/test.dart
@@ -142,6 +142,7 @@
'web_tests': _runWebUnitTests,
'web_integration_tests': _runWebIntegrationTests,
'web_long_running_tests': _runWebLongRunningTests,
+ 'flutter_plugins': _runFlutterPluginsTests,
});
} on ExitException catch (error) {
error.apply();
@@ -860,6 +861,47 @@
await _stopChromeDriver();
}
+/// Executes the test suite for the flutter/plugins repo.
+Future<void> _runFlutterPluginsTests() async {
+ Future<void> runAnalyze() async {
+ print('${green}Running analysis for flutter/plugins$reset');
+ final Directory checkout = Directory.systemTemp.createTempSync('plugins');
+ await runCommand(
+ 'git',
+ <String>[
+ '-c',
+ 'core.longPaths=true',
+ 'clone',
+ 'https://github.com/flutter/plugins.git',
+ '.'
+ ],
+ workingDirectory: checkout.path,
+ );
+ await runCommand(
+ pub,
+ <String>[
+ 'global',
+ 'activate',
+ 'flutter_plugin_tools',
+ ],
+ workingDirectory: checkout.path,
+ );
+ await runCommand(
+ pub,
+ <String>[
+ 'global',
+ 'run',
+ 'flutter_plugin_tools',
+ 'analyze',
+ ],
+ workingDirectory: checkout.path,
+ );
+ }
+ await selectSubshard(<String, ShardRunner>{
+ 'analyze': runAnalyze,
+ });
+}
+
// The `chromedriver` process created by this test.
//
// If an existing chromedriver is already available on port 4444, the existing