From ad72c7834231244f731e3c1ef12f40232b9fb97e Mon Sep 17 00:00:00 2001 From: "P.Y. Laligand" Date: Mon, 16 Oct 2017 10:58:39 -0700 Subject: [PATCH] Fix testing on Fuchsia. (#12563) --- packages/flutter_tools/bin/fuchsia_builder.dart | 3 ++- packages/flutter_tools/bin/fuchsia_tester.dart | 4 +++- 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/packages/flutter_tools/bin/fuchsia_builder.dart b/packages/flutter_tools/bin/fuchsia_builder.dart index 43a8299927..1c23fb2cd7 100644 --- a/packages/flutter_tools/bin/fuchsia_builder.dart +++ b/packages/flutter_tools/bin/fuchsia_builder.dart @@ -44,16 +44,17 @@ Future main(List args) async { executableContext.setVariable(Logger, new StdoutLogger()); await executableContext.runInZone(() { // Initialize the context with some defaults. + // This list must be kept in sync with lib/executable.dart. context.putIfAbsent(Stdio, () => const Stdio()); context.putIfAbsent(Platform, () => const LocalPlatform()); context.putIfAbsent(FileSystem, () => const LocalFileSystem()); context.putIfAbsent(ProcessManager, () => const LocalProcessManager()); + context.putIfAbsent(AnsiTerminal, () => new AnsiTerminal()); context.putIfAbsent(Logger, () => new StdoutLogger()); context.putIfAbsent(Cache, () => new Cache()); context.putIfAbsent(Config, () => new Config()); context.putIfAbsent(OperatingSystemUtils, () => new OperatingSystemUtils()); context.putIfAbsent(Usage, () => new Usage()); - context.putIfAbsent(AnsiTerminal, () => new AnsiTerminal()); return run(args); }); } diff --git a/packages/flutter_tools/bin/fuchsia_tester.dart b/packages/flutter_tools/bin/fuchsia_tester.dart index d357834a33..8c6892e0fb 100644 --- a/packages/flutter_tools/bin/fuchsia_tester.dart +++ b/packages/flutter_tools/bin/fuchsia_tester.dart @@ -40,15 +40,17 @@ Future main(List args) async { executableContext.setVariable(Logger, new StdoutLogger()); await executableContext.runInZone(() { // Initialize the context with some defaults. + // This list must be kept in sync with lib/executable.dart. + context.putIfAbsent(Stdio, () => const Stdio()); context.putIfAbsent(Platform, () => const LocalPlatform()); context.putIfAbsent(FileSystem, () => const LocalFileSystem()); context.putIfAbsent(ProcessManager, () => const LocalProcessManager()); + context.putIfAbsent(AnsiTerminal, () => new AnsiTerminal()); context.putIfAbsent(Logger, () => new StdoutLogger()); context.putIfAbsent(Cache, () => new Cache()); context.putIfAbsent(Config, () => new Config()); context.putIfAbsent(OperatingSystemUtils, () => new OperatingSystemUtils()); context.putIfAbsent(Usage, () => new Usage()); - context.putIfAbsent(AnsiTerminal, () => new AnsiTerminal()); return run(args); }); }