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

Side by Side Diff: pkg/analysis_server/test/integration/integration_tests.dart

Issue 1947813002: More strong mode clean-up (Closed) Base URL: https://github.com/dart-lang/sdk.git@master
Patch Set: Created 4 years, 7 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
« no previous file with comments | « no previous file | pkg/analysis_server/test/services/search/search_engine_test.dart » ('j') | 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.integration.analysis; 5 library test.integration.analysis;
6 6
7 import 'dart:async'; 7 import 'dart:async';
8 import 'dart:collection'; 8 import 'dart:collection';
9 import 'dart:convert'; 9 import 'dart:convert';
10 import 'dart:io'; 10 import 'dart:io';
11 11
12 import 'package:analysis_server/plugin/protocol/protocol.dart'; 12 import 'package:analysis_server/plugin/protocol/protocol.dart';
13 import 'package:analysis_server/src/constants.dart'; 13 import 'package:analysis_server/src/constants.dart';
14 import 'package:path/path.dart'; 14 import 'package:path/path.dart';
15 import 'package:unittest/unittest.dart'; 15 import 'package:unittest/unittest.dart';
16 16
17 import 'integration_test_methods.dart'; 17 import 'integration_test_methods.dart';
18 import 'protocol_matchers.dart'; 18 import 'protocol_matchers.dart';
19 19
20 const Matcher isBool = const isInstanceOf<bool>('bool'); 20 const Matcher isBool = const isInstanceOf<bool>();
21 21
22 const Matcher isInt = const isInstanceOf<int>('int'); 22 const Matcher isInt = const isInstanceOf<int>();
23 23
24 const Matcher isNotification = const MatchesJsonObject( 24 const Matcher isNotification = const MatchesJsonObject(
25 'notification', const {'event': isString}, 25 'notification', const {'event': isString},
26 optionalFields: const {'params': isMap}); 26 optionalFields: const {'params': isMap});
27 27
28 const Matcher isObject = isMap; 28 const Matcher isObject = isMap;
29 29
30 const Matcher isString = const isInstanceOf<String>('String'); 30 const Matcher isString = const isInstanceOf<String>();
31 31
32 final Matcher isResponse = new MatchesJsonObject('response', {'id': isString}, 32 final Matcher isResponse = new MatchesJsonObject('response', {'id': isString},
33 optionalFields: {'result': anything, 'error': isRequestError}); 33 optionalFields: {'result': anything, 'error': isRequestError});
34 34
35 Matcher isListOf(Matcher elementMatcher) => new _ListOf(elementMatcher); 35 Matcher isListOf(Matcher elementMatcher) => new _ListOf(elementMatcher);
36 36
37 Matcher isMapOf(Matcher keyMatcher, Matcher valueMatcher) => 37 Matcher isMapOf(Matcher keyMatcher, Matcher valueMatcher) =>
38 new _MapOf(keyMatcher, valueMatcher); 38 new _MapOf(keyMatcher, valueMatcher);
39 39
40 Matcher isOneOf(List<Matcher> choiceMatchers) => new _OneOf(choiceMatchers); 40 Matcher isOneOf(List<Matcher> choiceMatchers) => new _OneOf(choiceMatchers);
(...skipping 845 matching lines...) Expand 10 before | Expand all | Expand 10 after
886 void populateMismatches(item, List<MismatchDescriber> mismatches); 886 void populateMismatches(item, List<MismatchDescriber> mismatches);
887 887
888 /** 888 /**
889 * Create a [MismatchDescriber] describing a mismatch with a simple string. 889 * Create a [MismatchDescriber] describing a mismatch with a simple string.
890 */ 890 */
891 MismatchDescriber simpleDescription(String description) => 891 MismatchDescriber simpleDescription(String description) =>
892 (Description mismatchDescription) { 892 (Description mismatchDescription) {
893 mismatchDescription.add(description); 893 mismatchDescription.add(description);
894 }; 894 };
895 } 895 }
OLDNEW
« no previous file with comments | « no previous file | pkg/analysis_server/test/services/search/search_engine_test.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698