Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(191)

Side by Side Diff: pkg/analysis_server/test/domain_execution_test.dart

Issue 3001413002: Remove uses of the old plugin model from the analysis server (Closed)
Patch Set: Created 3 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
1 // Copyright (c) 2014, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2014, 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 import 'package:analysis_server/protocol/protocol.dart'; 5 import 'package:analysis_server/protocol/protocol.dart';
6 import 'package:analysis_server/protocol/protocol_generated.dart'; 6 import 'package:analysis_server/protocol/protocol_generated.dart';
7 import 'package:analysis_server/src/analysis_server.dart'; 7 import 'package:analysis_server/src/analysis_server.dart';
8 import 'package:analysis_server/src/domain_execution.dart'; 8 import 'package:analysis_server/src/domain_execution.dart';
9 import 'package:analysis_server/src/plugin/server_plugin.dart';
10 import 'package:analyzer/file_system/memory_file_system.dart'; 9 import 'package:analyzer/file_system/memory_file_system.dart';
11 import 'package:analyzer/instrumentation/instrumentation.dart'; 10 import 'package:analyzer/instrumentation/instrumentation.dart';
12 import 'package:analyzer/src/generated/sdk.dart'; 11 import 'package:analyzer/src/generated/sdk.dart';
13 import 'package:analyzer/src/generated/source.dart'; 12 import 'package:analyzer/src/generated/source.dart';
14 import 'package:analyzer/src/generated/source_io.dart'; 13 import 'package:analyzer/src/generated/source_io.dart';
15 import 'package:plugin/manager.dart';
16 import 'package:test/test.dart'; 14 import 'package:test/test.dart';
17 import 'package:test_reflective_loader/test_reflective_loader.dart'; 15 import 'package:test_reflective_loader/test_reflective_loader.dart';
18 16
19 import 'analysis_abstract.dart'; 17 import 'analysis_abstract.dart';
20 import 'mocks.dart'; 18 import 'mocks.dart';
21 19
22 main() { 20 main() {
23 defineReflectiveSuite(() { 21 defineReflectiveSuite(() {
24 defineReflectiveTests(ExecutionDomainTest); 22 defineReflectiveTests(ExecutionDomainTest);
25 }); 23 });
26 group('ExecutionDomainHandler', () { 24 group('ExecutionDomainHandler', () {
27 MemoryResourceProvider provider = new MemoryResourceProvider(); 25 MemoryResourceProvider provider = new MemoryResourceProvider();
28 AnalysisServer server; 26 AnalysisServer server;
29 ExecutionDomainHandler handler; 27 ExecutionDomainHandler handler;
30 28
31 setUp(() { 29 setUp(() {
32 ExtensionManager manager = new ExtensionManager();
33 ServerPlugin serverPlugin = new ServerPlugin();
34 manager.processPlugins([serverPlugin]);
35 server = new AnalysisServer( 30 server = new AnalysisServer(
36 new MockServerChannel(), 31 new MockServerChannel(),
37 provider, 32 provider,
38 new MockPackageMapProvider(), 33 new MockPackageMapProvider(),
39 serverPlugin,
40 new AnalysisServerOptions(), 34 new AnalysisServerOptions(),
41 new DartSdkManager('', false), 35 new DartSdkManager('', false),
42 InstrumentationService.NULL_SERVICE); 36 InstrumentationService.NULL_SERVICE);
43 handler = new ExecutionDomainHandler(server); 37 handler = new ExecutionDomainHandler(server);
44 }); 38 });
45 39
46 group('createContext/deleteContext', () { 40 group('createContext/deleteContext', () {
47 test('create/delete multiple contexts', () { 41 test('create/delete multiple contexts', () {
48 Request request = 42 Request request =
49 new ExecutionCreateContextParams('/a/b.dart').toRequest('0'); 43 new ExecutionCreateContextParams('/a/b.dart').toRequest('0');
(...skipping 190 matching lines...) Expand 10 before | Expand all | Expand 10 after
240 * A [Source] that knows it's [fullName]. 234 * A [Source] that knows it's [fullName].
241 */ 235 */
242 class TestSource implements Source { 236 class TestSource implements Source {
243 String fullName; 237 String fullName;
244 238
245 TestSource(this.fullName); 239 TestSource(this.fullName);
246 240
247 @override 241 @override
248 noSuchMethod(Invocation invocation) => super.noSuchMethod(invocation); 242 noSuchMethod(Invocation invocation) => super.noSuchMethod(invocation);
249 } 243 }
OLDNEW
« no previous file with comments | « pkg/analysis_server/test/domain_analysis_test.dart ('k') | pkg/analysis_server/test/domain_server_test.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698