| OLD | NEW |
| 1 // Copyright (c) 2015, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2015, 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 analyzer.test.instrumentation.instrumentation_test; | 5 library analyzer.test.instrumentation.instrumentation_test; |
| 6 | 6 |
| 7 import 'dart:async'; | 7 import 'dart:async'; |
| 8 | 8 |
| 9 import 'package:analyzer/instrumentation/instrumentation.dart'; | 9 import 'package:analyzer/instrumentation/instrumentation.dart'; |
| 10 import 'package:test/test.dart'; | 10 import 'package:test/test.dart'; |
| (...skipping 148 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 159 } | 159 } |
| 160 | 160 |
| 161 class TestInstrumentationServer implements InstrumentationServer { | 161 class TestInstrumentationServer implements InstrumentationServer { |
| 162 StringBuffer normalChannel = new StringBuffer(); | 162 StringBuffer normalChannel = new StringBuffer(); |
| 163 StringBuffer priorityChannel = new StringBuffer(); | 163 StringBuffer priorityChannel = new StringBuffer(); |
| 164 | 164 |
| 165 @override | 165 @override |
| 166 String get sessionId => ''; | 166 String get sessionId => ''; |
| 167 | 167 |
| 168 @override | 168 @override |
| 169 String get describe => 'test instrumentation'; |
| 170 |
| 171 @override |
| 169 void log(String message) { | 172 void log(String message) { |
| 170 normalChannel.writeln(message); | 173 normalChannel.writeln(message); |
| 171 } | 174 } |
| 172 | 175 |
| 173 @override | 176 @override |
| 174 void logWithPriority(String message) { | 177 void logWithPriority(String message) { |
| 175 priorityChannel.writeln(message); | 178 priorityChannel.writeln(message); |
| 176 } | 179 } |
| 177 | 180 |
| 178 @override | 181 @override |
| 179 Future shutdown() async { | 182 Future shutdown() async { |
| 180 // Ignored | 183 // Ignored |
| 181 } | 184 } |
| 182 } | 185 } |
| OLD | NEW |