| Index: editor/tools/plugins/com.google.dart.tools.ui_test/src/com/google/dart/tools/ui/refactoring/RenameLocalVariableProcessorTest.java
|
| diff --git a/editor/tools/plugins/com.google.dart.tools.ui_test/src/com/google/dart/tools/ui/refactoring/RenameLocalVariableProcessorTest.java b/editor/tools/plugins/com.google.dart.tools.ui_test/src/com/google/dart/tools/ui/refactoring/RenameLocalVariableProcessorTest.java
|
| index cb2f4a54989673459f0090e4e959a9571dce045c..59b2024436c334bd604c70a4a97d4bbbcac4fc3e 100644
|
| --- a/editor/tools/plugins/com.google.dart.tools.ui_test/src/com/google/dart/tools/ui/refactoring/RenameLocalVariableProcessorTest.java
|
| +++ b/editor/tools/plugins/com.google.dart.tools.ui_test/src/com/google/dart/tools/ui/refactoring/RenameLocalVariableProcessorTest.java
|
| @@ -216,6 +216,46 @@ public final class RenameLocalVariableProcessorTest extends RefactoringTest {
|
| "}");
|
| }
|
|
|
| + public void test_OK_parameter_named_onDeclaration() throws Exception {
|
| + setTestUnitContent(
|
| + "// filler filler filler filler filler filler filler filler filler filler",
|
| + "f({test: 10}) {}",
|
| + "main() {",
|
| + " f(test: 42);",
|
| + "}",
|
| + "");
|
| + DartVariableDeclaration variable = findElement("test: 10");
|
| + // do rename
|
| + renameLocalVariable(variable, "newName");
|
| + assertTestUnitContent(
|
| + "// filler filler filler filler filler filler filler filler filler filler",
|
| + "f({newName: 10}) {}",
|
| + "main() {",
|
| + " f(newName: 42);",
|
| + "}",
|
| + "");
|
| + }
|
| +
|
| + public void test_OK_parameter_named_onInvocation() throws Exception {
|
| + setTestUnitContent(
|
| + "// filler filler filler filler filler filler filler filler filler filler",
|
| + "f({test: 10}) {}",
|
| + "main() {",
|
| + " f(test: 42);",
|
| + "}",
|
| + "");
|
| + DartVariableDeclaration variable = findElement("test: 42");
|
| + // do rename
|
| + renameLocalVariable(variable, "newName");
|
| + assertTestUnitContent(
|
| + "// filler filler filler filler filler filler filler filler filler filler",
|
| + "f({newName: 10}) {}",
|
| + "main() {",
|
| + " f(newName: 42);",
|
| + "}",
|
| + "");
|
| + }
|
| +
|
| public void test_OK_parameter_onDeclaration() throws Exception {
|
| setTestUnitContent(
|
| "// filler filler filler filler filler filler filler filler filler filler",
|
|
|