Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(309)

Unified Diff: pkg/analysis_server/test/edit/refactoring_test.dart

Issue 749173002: Issue 21613. Fix for renaming FieldFormalParameterElement. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 6 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « pkg/analysis_server/lib/src/edit/edit_domain.dart ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: pkg/analysis_server/test/edit/refactoring_test.dart
diff --git a/pkg/analysis_server/test/edit/refactoring_test.dart b/pkg/analysis_server/test/edit/refactoring_test.dart
index 76350befedc40c6a66bf5343ad231ebb8330151e..7d4b2b2d484024941bd2de23b9381d4a42e7a37c 100644
--- a/pkg/analysis_server/test/edit/refactoring_test.dart
+++ b/pkg/analysis_server/test/edit/refactoring_test.dart
@@ -1071,6 +1071,7 @@ main() {
addTestFile('''
class A {
var test = 0;
+ A(this.test);
main() {
print(test);
}
@@ -1081,6 +1082,30 @@ class A {
}, '''
class A {
var newName = 0;
+ A(this.newName);
+ main() {
+ print(newName);
+ }
+}
+''');
+ }
+
+ test_classMember_field_onFieldFormalParameter() {
+ addTestFile('''
+class A {
+ var test = 0;
+ A(this.test);
+ main() {
+ print(test);
+ }
+}
+''');
+ return assertSuccessfulRefactoring(() {
+ return sendRenameRequest('test);', 'newName');
+ }, '''
+class A {
+ var newName = 0;
+ A(this.newName);
main() {
print(newName);
}
« no previous file with comments | « pkg/analysis_server/lib/src/edit/edit_domain.dart ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698