[flutter_tool] fix NPE in daemon caused by returning null connection info from experimental web runner (#46909)
This commit is contained in:
@@ -535,7 +535,7 @@ class _ExperimentalResidentWebRunner extends ResidentWebRunner {
|
||||
_wipConnection = await chromeTab.connect();
|
||||
}
|
||||
appStartedCompleter?.complete();
|
||||
connectionInfoCompleter?.complete();
|
||||
connectionInfoCompleter?.complete(DebugConnectionInfo());
|
||||
if (stayResident) {
|
||||
await waitForAppToFinish();
|
||||
} else {
|
||||
|
||||
@@ -378,7 +378,10 @@ void main() {
|
||||
unawaited(residentWebRunner.run(
|
||||
connectionInfoCompleter: connectionInfoCompleter,
|
||||
));
|
||||
await connectionInfoCompleter.future;
|
||||
final DebugConnectionInfo debugConnectionInfo = await connectionInfoCompleter.future;
|
||||
|
||||
expect(debugConnectionInfo, isNotNull);
|
||||
|
||||
final OperationResult result = await residentWebRunner.restart(fullRestart: false);
|
||||
|
||||
expect(testLogger.statusText, contains('Reloaded application in'));
|
||||
|
||||
Reference in New Issue
Block a user