| 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.domain.execution; | 5 library test.domain.execution; |
| 6 | 6 |
| 7 import 'package:analyzer/file_system/physical_file_system.dart'; | 7 import 'package:analyzer/file_system/physical_file_system.dart'; |
| 8 import 'package:analysis_server/src/analysis_server.dart'; | 8 import 'package:analysis_server/src/analysis_server.dart'; |
| 9 import 'package:analysis_server/src/constants.dart'; | 9 import 'package:analysis_server/src/constants.dart'; |
| 10 import 'package:analysis_server/src/domain_execution.dart'; | 10 import 'package:analysis_server/src/domain_execution.dart'; |
| (...skipping 201 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 212 expect(referencedFiles, isNotNull); | 212 expect(referencedFiles, isNotNull); |
| 213 expect(referencedFiles.length, equals(2)); | 213 expect(referencedFiles.length, equals(2)); |
| 214 expect(referencedFiles[0], equals(source6.fullName)); | 214 expect(referencedFiles[0], equals(source6.fullName)); |
| 215 expect(referencedFiles[1], equals(source7.fullName)); | 215 expect(referencedFiles[1], equals(source7.fullName)); |
| 216 } | 216 } |
| 217 }); | 217 }); |
| 218 | 218 |
| 219 ExecutionDomainHandler handler = new ExecutionDomainHandler(server); | 219 ExecutionDomainHandler handler = new ExecutionDomainHandler(server); |
| 220 Request request = new ExecutionSetSubscriptionsParams( | 220 Request request = new ExecutionSetSubscriptionsParams( |
| 221 [ExecutionService.LAUNCH_DATA]).toRequest('0'); | 221 [ExecutionService.LAUNCH_DATA]).toRequest('0'); |
| 222 Response response = handler.handleRequest(request); | 222 handler.handleRequest(request); |
| 223 | 223 |
| 224 // controller.add(null); | 224 // controller.add(null); |
| 225 expect(unsentNotifications, isEmpty); | 225 expect(unsentNotifications, isEmpty); |
| 226 }); | 226 }); |
| 227 }); | 227 }); |
| 228 } | 228 } |
| 229 | 229 |
| 230 /** | 230 /** |
| 231 * A [Source] that knows it's [fullName]. | 231 * A [Source] that knows it's [fullName]. |
| 232 */ | 232 */ |
| (...skipping 27 matching lines...) Expand all Loading... |
| 260 @override | 260 @override |
| 261 Description describe(Description description) { | 261 Description describe(Description description) { |
| 262 return description.add('ExecutableFile($expectedFile, $expectedKind)'); | 262 return description.add('ExecutableFile($expectedFile, $expectedKind)'); |
| 263 } | 263 } |
| 264 | 264 |
| 265 @override | 265 @override |
| 266 bool matches(item, Map matchState) { | 266 bool matches(item, Map matchState) { |
| 267 if (item is! ExecutableFile) { | 267 if (item is! ExecutableFile) { |
| 268 return false; | 268 return false; |
| 269 } | 269 } |
| 270 ExecutableFile file = item; | |
| 271 return item.file == expectedFile && item.kind == expectedKind; | 270 return item.file == expectedFile && item.kind == expectedKind; |
| 272 } | 271 } |
| 273 } | 272 } |
| OLD | NEW |