| 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_reflective_loader/test_reflective_loader.dart'; | 11 import 'package:test_reflective_loader/test_reflective_loader.dart'; |
| 11 import 'package:unittest/unittest.dart'; | |
| 12 | 12 |
| 13 import '../../utils.dart'; | 13 import '../../utils.dart'; |
| 14 import 'abstract_rename.dart'; | 14 import 'abstract_rename.dart'; |
| 15 | 15 |
| 16 main() { | 16 main() { |
| 17 initializeTestEnvironment(); | 17 initializeTestEnvironment(); |
| 18 defineReflectiveTests(RenameClassMemberTest); | 18 defineReflectiveSuite(() { |
| 19 defineReflectiveTests(RenameClassMemberTest); |
| 20 }); |
| 19 } | 21 } |
| 20 | 22 |
| 21 @reflectiveTest | 23 @reflectiveTest |
| 22 class RenameClassMemberTest extends RenameRefactoringTest { | 24 class RenameClassMemberTest extends RenameRefactoringTest { |
| 23 test_checkFinalConditions_classNameConflict_sameClass() async { | 25 test_checkFinalConditions_classNameConflict_sameClass() async { |
| 24 indexTestUnit(''' | 26 indexTestUnit(''' |
| 25 class NewName { | 27 class NewName { |
| 26 void test() {} | 28 void test() {} |
| 27 } | 29 } |
| 28 '''); | 30 '''); |
| (...skipping 864 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 893 // validate change | 895 // validate change |
| 894 return assertSuccessfulRefactoring(''' | 896 return assertSuccessfulRefactoring(''' |
| 895 class A<NewName> { | 897 class A<NewName> { |
| 896 NewName field; | 898 NewName field; |
| 897 List<NewName> items; | 899 List<NewName> items; |
| 898 NewName method(NewName p) => null; | 900 NewName method(NewName p) => null; |
| 899 } | 901 } |
| 900 '''); | 902 '''); |
| 901 } | 903 } |
| 902 } | 904 } |
| OLD | NEW |