| 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.computer.element; | 5 library test.computer.element; |
| 6 | 6 |
| 7 import 'dart:mirrors'; | 7 import 'dart:mirrors'; |
| 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_server.dart'; | 10 import 'package:analysis_server/src/protocol_server.dart'; |
| (...skipping 97 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 108 LENGTH: 20, | 108 LENGTH: 20, |
| 109 START_LINE: -1, | 109 START_LINE: -1, |
| 110 START_COLUMN: -1 | 110 START_COLUMN: -1 |
| 111 }, | 111 }, |
| 112 MESSAGE: 'my message' | 112 MESSAGE: 'my message' |
| 113 }); | 113 }); |
| 114 } | 114 } |
| 115 } | 115 } |
| 116 | 116 |
| 117 | 117 |
| 118 @ReflectiveTestCase() |
| 118 class ElementKindTest { | 119 class ElementKindTest { |
| 119 void test_fromEngine() { | 120 void test_fromEngine() { |
| 120 expect( | 121 expect( |
| 121 newElementKind_fromEngine(engine.ElementKind.CLASS), | 122 newElementKind_fromEngine(engine.ElementKind.CLASS), |
| 122 ElementKind.CLASS); | 123 ElementKind.CLASS); |
| 123 expect( | 124 expect( |
| 124 newElementKind_fromEngine(engine.ElementKind.COMPILATION_UNIT), | 125 newElementKind_fromEngine(engine.ElementKind.COMPILATION_UNIT), |
| 125 ElementKind.COMPILATION_UNIT); | 126 ElementKind.COMPILATION_UNIT); |
| 126 expect( | 127 expect( |
| 127 newElementKind_fromEngine(engine.ElementKind.CONSTRUCTOR), | 128 newElementKind_fromEngine(engine.ElementKind.CONSTRUCTOR), |
| (...skipping 382 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 510 ApiEnum apiValue = convert(engineValue); | 511 ApiEnum apiValue = convert(engineValue); |
| 511 expect(apiValue, equals(expectedResult)); | 512 expect(apiValue, equals(expectedResult)); |
| 512 } | 513 } |
| 513 } else { | 514 } else { |
| 514 ApiEnum apiValue = convert(engineValue); | 515 ApiEnum apiValue = convert(engineValue); |
| 515 expect(apiValue.name, equals(enumName)); | 516 expect(apiValue.name, equals(enumName)); |
| 516 } | 517 } |
| 517 }); | 518 }); |
| 518 } | 519 } |
| 519 } | 520 } |
| OLD | NEW |