[flutter_tool] Observatory connection error handling cleanup (#38353)

This commit is contained in:
Zachary Anderson
2019-08-15 12:13:03 -07:00
committed by GitHub
parent f5dcbdab3a
commit a40ab895cf
6 changed files with 266 additions and 95 deletions

View File

@@ -153,7 +153,7 @@ ro.build.version.codename=REL
typedef ProcessFactory = Process Function(List<String> command);
/// A ProcessManager that starts Processes by delegating to a ProcessFactory.
class MockProcessManager implements ProcessManager {
class MockProcessManager extends Mock implements ProcessManager {
ProcessFactory processFactory = (List<String> commands) => MockProcess();
bool canRunSucceeds = true;
bool runSucceeds = true;
@@ -180,9 +180,6 @@ class MockProcessManager implements ProcessManager {
commands = command;
return Future<Process>.value(processFactory(command));
}
@override
dynamic noSuchMethod(Invocation invocation) => null;
}
/// A process that exits successfully with no output and ignores all input.