prefer const constructor (#8292)

This commit is contained in:
Alexandre Ardhuin
2017-02-20 23:07:16 +01:00
committed by Adam Barth
parent 8b820ccc54
commit 2888139c6b
21 changed files with 34 additions and 34 deletions

View File

@@ -42,9 +42,9 @@ 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 LocalPlatform());
testContext.putIfAbsent(FileSystem, () => new LocalFileSystem());
testContext.putIfAbsent(ProcessManager, () => new LocalProcessManager());
testContext.putIfAbsent(Platform, () => const LocalPlatform());
testContext.putIfAbsent(FileSystem, () => const LocalFileSystem());
testContext.putIfAbsent(ProcessManager, () => const LocalProcessManager());
testContext.putIfAbsent(Logger, () => new BufferLogger());
testContext.putIfAbsent(Config, () => new Config());