| 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.analysis.notification.outline; | 5 library test.analysis.notification.outline; |
| 6 | 6 |
| 7 import 'dart:async'; | 7 import 'dart:async'; |
| 8 | 8 |
| 9 import 'package:analysis_server/src/constants.dart'; | 9 import 'package:analysis_server/src/constants.dart'; |
| 10 import 'package:analysis_server/src/protocol.dart'; | 10 import 'package:analysis_server/src/protocol.dart'; |
| (...skipping 188 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 199 { | 199 { |
| 200 Outline outline = outlines_A[8]; | 200 Outline outline = outlines_A[8]; |
| 201 Element element = outline.element; | 201 Element element = outline.element; |
| 202 expect(element.kind, ElementKind.GETTER); | 202 expect(element.kind, ElementKind.GETTER); |
| 203 expect(element.name, "propA"); | 203 expect(element.name, "propA"); |
| 204 { | 204 { |
| 205 Location location = element.location; | 205 Location location = element.location; |
| 206 expect(location.offset, testCode.indexOf("propA => null;")); | 206 expect(location.offset, testCode.indexOf("propA => null;")); |
| 207 expect(location.length, "propA".length); | 207 expect(location.length, "propA".length); |
| 208 } | 208 } |
| 209 expect(element.parameters, ""); | 209 expect(element.parameters, isNull); |
| 210 expect(element.returnType, "String"); | 210 expect(element.returnType, "String"); |
| 211 } | 211 } |
| 212 { | 212 { |
| 213 Outline outline = outlines_A[9]; | 213 Outline outline = outlines_A[9]; |
| 214 Element element = outline.element; | 214 Element element = outline.element; |
| 215 expect(element.kind, ElementKind.SETTER); | 215 expect(element.kind, ElementKind.SETTER); |
| 216 expect(element.name, "propB"); | 216 expect(element.name, "propB"); |
| 217 { | 217 { |
| 218 Location location = element.location; | 218 Location location = element.location; |
| 219 expect(location.offset, testCode.indexOf("propB(int v) {}")); | 219 expect(location.offset, testCode.indexOf("propB(int v) {}")); |
| (...skipping 534 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 754 Location location = element.location; | 754 Location location = element.location; |
| 755 expect(location.offset, testCode.indexOf("propB(int v) {}")); | 755 expect(location.offset, testCode.indexOf("propB(int v) {}")); |
| 756 expect(location.length, "propB".length); | 756 expect(location.length, "propB".length); |
| 757 } | 757 } |
| 758 expect(element.parameters, "(int v)"); | 758 expect(element.parameters, "(int v)"); |
| 759 expect(element.returnType, ""); | 759 expect(element.returnType, ""); |
| 760 } | 760 } |
| 761 }); | 761 }); |
| 762 } | 762 } |
| 763 } | 763 } |
| OLD | NEW |