Annotate entrypoints in the "isolate spawner" files generated by flutter test --experimental-faster-testing (#160694)

This fixes the test timeouts
(https://ci.chromium.org/ui/p/flutter/builders/prod/Mac%20tool_integration_tests_2_5/1951/overview)
introduced by the most recent Dart SDK roll
(895f0e291a).
This commit is contained in:
Derek Xu 2024-12-20 22:15:13 -05:00 committed by GitHub
parent fe4c672e79
commit 5036e58c23
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -394,6 +394,7 @@ void createChannelAndConnect(String path, String name, Function testMain) {
channel.pipe(RemoteListener.start(() => testMain));
}
@pragma('vm:entry-point')
void testMain() {
final String route = PlatformDispatcher.instance.defaultRouteName;
switch (route) {
@ -418,6 +419,7 @@ void testMain() {
}
}
@pragma('vm:entry-point')
void main([dynamic sendPort]) {
if (sendPort is SendPort) {
final ReceivePort receivePort = ReceivePort();
@ -495,6 +497,7 @@ Future<void> spawn({
commandPort.send(<Object>['spawn', port, entrypoint, route]);
}
@pragma('vm:entry-point')
void main() async {
final String route = PlatformDispatcher.instance.defaultRouteName;