| OLD | NEW |
| 1 // Copyright (c) 2016, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2016, the Dart project authors. Please see the AUTHORS file |
| 2 // for details. All rights reserved. Use of this source code is governed by a | 2 // for details. All rights reserved. Use of this source code is governed by a |
| 3 // BSD-style license that can be found in the LICENSE file. | 3 // BSD-style license that can be found in the LICENSE file. |
| 4 | 4 |
| 5 library test.analysis_server.src.single_context_manager; | 5 library test.analysis_server.src.single_context_manager; |
| 6 | 6 |
| 7 import 'dart:core' hide Resource; | 7 import 'dart:core' hide Resource; |
| 8 | 8 |
| 9 import 'package:analysis_server/src/single_context_manager.dart'; | 9 import 'package:analysis_server/src/single_context_manager.dart'; |
| 10 import 'package:analyzer/file_system/memory_file_system.dart'; | 10 import 'package:analyzer/file_system/memory_file_system.dart'; |
| (...skipping 51 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 62 } | 62 } |
| 63 | 63 |
| 64 void setUp() { | 64 void setUp() { |
| 65 packageResolver = new TestUriResolver(); | 65 packageResolver = new TestUriResolver(); |
| 66 | 66 |
| 67 _processRequiredPlugins(); | 67 _processRequiredPlugins(); |
| 68 DartSdkManager sdkManager = new DartSdkManager((_) { | 68 DartSdkManager sdkManager = new DartSdkManager((_) { |
| 69 return new MockSdk(); | 69 return new MockSdk(); |
| 70 }); | 70 }); |
| 71 manager = new SingleContextManager(resourceProvider, sdkManager, | 71 manager = new SingleContextManager(resourceProvider, sdkManager, |
| 72 () => packageResolver, analysisFilesGlobs); | 72 (_) => packageResolver, analysisFilesGlobs, new AnalysisOptionsImpl()); |
| 73 callbacks = new TestContextManagerCallbacks(resourceProvider); | 73 callbacks = new TestContextManagerCallbacks(resourceProvider); |
| 74 manager.callbacks = callbacks; | 74 manager.callbacks = callbacks; |
| 75 } | 75 } |
| 76 | 76 |
| 77 void test_isIgnored_false() { | 77 void test_isIgnored_false() { |
| 78 String project = '/project'; | 78 String project = '/project'; |
| 79 manager.setRoots(<String>[project], <String>[], <String, String>{}); | 79 manager.setRoots(<String>[project], <String>[], <String, String>{}); |
| 80 expect(manager.isIgnored('$project/file.dart'), isFalse); | 80 expect(manager.isIgnored('$project/file.dart'), isFalse); |
| 81 } | 81 } |
| 82 | 82 |
| (...skipping 447 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 530 manager.processPlugins(plugins); | 530 manager.processPlugins(plugins); |
| 531 } | 531 } |
| 532 } | 532 } |
| 533 | 533 |
| 534 class TestUriResolver extends UriResolver { | 534 class TestUriResolver extends UriResolver { |
| 535 @override | 535 @override |
| 536 Source resolveAbsolute(Uri uri, [Uri actualUri]) { | 536 Source resolveAbsolute(Uri uri, [Uri actualUri]) { |
| 537 return null; | 537 return null; |
| 538 } | 538 } |
| 539 } | 539 } |
| OLD | NEW |