Index: pkg/analysis_server/test/analysis_abstract.dart |
diff --git a/pkg/analysis_server/test/analysis_abstract.dart b/pkg/analysis_server/test/analysis_abstract.dart |
index b76102d8c46b799c98a8afb5066ff6265cb4f481..0db5841cf5dfce262c8af70b482c8beca1777c27 100644 |
--- a/pkg/analysis_server/test/analysis_abstract.dart |
+++ b/pkg/analysis_server/test/analysis_abstract.dart |
@@ -125,6 +125,7 @@ class AbstractAnalysisTest { |
// |
// Create server |
// |
+ MockSdk sdk = new MockSdk(resourceProvider: resourceProvider); |
return new AnalysisServer( |
serverChannel, |
resourceProvider, |
@@ -132,7 +133,7 @@ class AbstractAnalysisTest { |
index, |
serverPlugin, |
new AnalysisServerOptions(), |
- new DartSdkManager('', false, (_) => new MockSdk()), |
+ new DartSdkManager('/', false, (_) => sdk), |
InstrumentationService.NULL_SERVICE); |
} |
@@ -143,10 +144,10 @@ class AbstractAnalysisTest { |
/** |
* Creates a project `/project`. |
*/ |
- void createProject() { |
+ void createProject({Map<String, String> packageRoots}) { |
resourceProvider.newFolder(projectPath); |
Request request = |
- new AnalysisSetAnalysisRootsParams([projectPath], []).toRequest('0'); |
+ new AnalysisSetAnalysisRootsParams([projectPath], [], packageRoots: packageRoots).toRequest('0'); |
handleSuccessfulRequest(request, handler: analysisHandler); |
} |