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.services.refactoring.rename_class_member; | 5 library test.services.refactoring.rename_class_member; |
6 | 6 |
7 import 'package:analysis_server/plugin/protocol/protocol.dart'; | 7 import 'package:analysis_server/plugin/protocol/protocol.dart'; |
8 import 'package:analysis_server/src/services/correction/status.dart'; | 8 import 'package:analysis_server/src/services/correction/status.dart'; |
9 import 'package:analyzer/src/generated/source.dart'; | 9 import 'package:analyzer/src/generated/source.dart'; |
10 import 'package:test/test.dart'; | 10 import 'package:test/test.dart'; |
11 import 'package:test_reflective_loader/test_reflective_loader.dart'; | 11 import 'package:test_reflective_loader/test_reflective_loader.dart'; |
12 | 12 |
13 import '../../utils.dart'; | |
14 import 'abstract_rename.dart'; | 13 import 'abstract_rename.dart'; |
15 | 14 |
16 main() { | 15 main() { |
17 initializeTestEnvironment(); | |
18 defineReflectiveSuite(() { | 16 defineReflectiveSuite(() { |
19 defineReflectiveTests(RenameClassMemberTest); | 17 defineReflectiveTests(RenameClassMemberTest); |
20 }); | 18 }); |
21 } | 19 } |
22 | 20 |
23 @reflectiveTest | 21 @reflectiveTest |
24 class RenameClassMemberTest extends RenameRefactoringTest { | 22 class RenameClassMemberTest extends RenameRefactoringTest { |
25 test_checkFinalConditions_classNameConflict_sameClass() async { | 23 test_checkFinalConditions_classNameConflict_sameClass() async { |
26 indexTestUnit(''' | 24 indexTestUnit(''' |
27 class NewName { | 25 class NewName { |
(...skipping 867 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
895 // validate change | 893 // validate change |
896 return assertSuccessfulRefactoring(''' | 894 return assertSuccessfulRefactoring(''' |
897 class A<NewName> { | 895 class A<NewName> { |
898 NewName field; | 896 NewName field; |
899 List<NewName> items; | 897 List<NewName> items; |
900 NewName method(NewName p) => null; | 898 NewName method(NewName p) => null; |
901 } | 899 } |
902 '''); | 900 '''); |
903 } | 901 } |
904 } | 902 } |
OLD | NEW |