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

Side by Side Diff: pkg/analysis_server/test/services/completion/completion_manager_test.dart

Issue 691853006: display completion performance in new server status page (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: merge Created 6 years, 1 month 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 | Annotate | Revision Log
« no previous file with comments | « pkg/analysis_server/test/services/completion/completion_computer_test.dart ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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 library test.services.completion.manager; 5 library test.services.completion.manager;
6 6
7 import 'package:analysis_server/src/services/completion/completion_manager.dart' ; 7 import 'package:analysis_server/src/services/completion/completion_manager.dart' ;
8 import 'package:analysis_server/src/services/completion/dart_completion_manager. dart'; 8 import 'package:analysis_server/src/services/completion/dart_completion_manager. dart';
9 import '../../abstract_context.dart'; 9 import '../../abstract_context.dart';
10 import '../../reflective_tests.dart'; 10 import '../../reflective_tests.dart';
11 import 'package:analyzer/src/generated/source.dart'; 11 import 'package:analyzer/src/generated/source.dart';
12 import 'package:unittest/unittest.dart'; 12 import 'package:unittest/unittest.dart';
13 13
14 main() { 14 main() {
15 groupSep = ' | '; 15 groupSep = ' | ';
16 runReflectiveTests(CompletionManagerTest); 16 runReflectiveTests(CompletionManagerTest);
17 } 17 }
18 18
19 @ReflectiveTestCase() 19 @ReflectiveTestCase()
20 class CompletionManagerTest extends AbstractContextTest { 20 class CompletionManagerTest extends AbstractContextTest {
21 var perf = new CompletionPerformance();
21 22
22 test_dart() { 23 test_dart() {
23 Source source = addSource('/does/not/exist.dart', ''); 24 Source source = addSource('/does/not/exist.dart', '');
24 var manager = CompletionManager.create(context, source, 0, null); 25 var manager = CompletionManager.create(context, source, 0, null, perf);
25 expect(manager.runtimeType, DartCompletionManager); 26 expect(manager.runtimeType, DartCompletionManager);
26 } 27 }
27 28
28 test_html() { 29 test_html() {
29 Source source = addSource('/does/not/exist.html', ''); 30 Source source = addSource('/does/not/exist.html', '');
30 var manager = CompletionManager.create(context, source, 0, null); 31 var manager = CompletionManager.create(context, source, 0, null, perf);
31 expect(manager.runtimeType, NoOpCompletionManager); 32 expect(manager.runtimeType, NoOpCompletionManager);
32 } 33 }
33 34
34 test_null_context() { 35 test_null_context() {
35 Source source = addSource('/does/not/exist.dart', ''); 36 Source source = addSource('/does/not/exist.dart', '');
36 var manager = CompletionManager.create(null, source, 0, null); 37 var manager = CompletionManager.create(null, source, 0, null, perf);
37 expect(manager.runtimeType, NoOpCompletionManager); 38 expect(manager.runtimeType, NoOpCompletionManager);
38 } 39 }
39 40
40 test_other() { 41 test_other() {
41 Source source = addSource('/does/not/exist.foo', ''); 42 Source source = addSource('/does/not/exist.foo', '');
42 var manager = CompletionManager.create(context, source, 0, null); 43 var manager = CompletionManager.create(context, source, 0, null, perf);
43 expect(manager.runtimeType, NoOpCompletionManager); 44 expect(manager.runtimeType, NoOpCompletionManager);
44 } 45 }
45 } 46 }
OLDNEW
« no previous file with comments | « pkg/analysis_server/test/services/completion/completion_computer_test.dart ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698