| OLD | NEW |
| 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'; |
| (...skipping 186 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 197 return server.exitCode.timeout(SHUTDOWN_TIMEOUT, onTimeout: () { | 197 return server.exitCode.timeout(SHUTDOWN_TIMEOUT, onTimeout: () { |
| 198 return server.kill(); | 198 return server.kill(); |
| 199 }); | 199 }); |
| 200 } | 200 } |
| 201 } | 201 } |
| 202 | 202 |
| 203 final Matcher isResponse = new MatchesJsonObject('response', { | 203 final Matcher isResponse = new MatchesJsonObject('response', { |
| 204 'id': isString | 204 'id': isString |
| 205 }, optionalFields: { | 205 }, optionalFields: { |
| 206 'result': anything, | 206 'result': anything, |
| 207 'error': isError | 207 'error': isRequestError |
| 208 }); | 208 }); |
| 209 | 209 |
| 210 const Matcher isNotification = const MatchesJsonObject('notification', const { | 210 const Matcher isNotification = const MatchesJsonObject('notification', const { |
| 211 'event': isString | 211 'event': isString |
| 212 }, optionalFields: const { | 212 }, optionalFields: const { |
| 213 'params': isMap | 213 'params': isMap |
| 214 }); | 214 }); |
| 215 | 215 |
| 216 const Matcher isString = const isInstanceOf<String>('String'); | 216 const Matcher isString = const isInstanceOf<String>('String'); |
| 217 | 217 |
| (...skipping 611 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 829 */ | 829 */ |
| 830 void _recordStdio(String line) { | 830 void _recordStdio(String line) { |
| 831 double elapsedTime = _time.elapsedTicks / _time.frequency; | 831 double elapsedTime = _time.elapsedTicks / _time.frequency; |
| 832 line = "$elapsedTime: $line"; | 832 line = "$elapsedTime: $line"; |
| 833 if (_debuggingStdio) { | 833 if (_debuggingStdio) { |
| 834 print(line); | 834 print(line); |
| 835 } | 835 } |
| 836 _recordedStdio.add(line); | 836 _recordedStdio.add(line); |
| 837 } | 837 } |
| 838 } | 838 } |
| OLD | NEW |