diff --git a/packages/flutter_tools/test/src/context.dart b/packages/flutter_tools/test/src/context.dart index 04aa87f60d..ff8961c665 100644 --- a/packages/flutter_tools/test/src/context.dart +++ b/packages/flutter_tools/test/src/context.dart @@ -42,7 +42,7 @@ void testUsingContext(String description, dynamic testMethod(), { // Initialize the test context with some default mocks. // Seed these context entries first since others depend on them - testContext.putIfAbsent(Platform, () => new _FakePlatform()); + testContext.putIfAbsent(Platform, () => const LocalPlatform()); testContext.putIfAbsent(FileSystem, () => const LocalFileSystem()); testContext.putIfAbsent(ProcessManager, () => const LocalProcessManager()); testContext.putIfAbsent(Logger, () => new BufferLogger()); @@ -140,13 +140,6 @@ class MockSimControl extends Mock implements SimControl { } } -class _FakePlatform extends FakePlatform { - _FakePlatform() : super.fromPlatform(const LocalPlatform()); - - @override - bool get isWindows => false; -} - class MockOperatingSystemUtils extends Mock implements OperatingSystemUtils {} class MockIOSSimulatorUtils extends Mock implements IOSSimulatorUtils {}