| Index: pkg/analysis_server/test/services/correction/fix_test.dart
|
| diff --git a/pkg/analysis_server/test/services/correction/fix_test.dart b/pkg/analysis_server/test/services/correction/fix_test.dart
|
| index 232d5602e352af658a1891214df2c0dd843ae714..d833738ee50c86151c2ca5b77d185caccb841560 100644
|
| --- a/pkg/analysis_server/test/services/correction/fix_test.dart
|
| +++ b/pkg/analysis_server/test/services/correction/fix_test.dart
|
| @@ -922,6 +922,34 @@ class A {
|
| ''');
|
| }
|
|
|
| + void test_createLocalVariable_functionType_named() {
|
| + _indexTestUnit('''
|
| +typedef MY_FUNCTION(int p);
|
| +foo(MY_FUNCTION f) {}
|
| +main() {
|
| + foo(bar);
|
| +}
|
| +''');
|
| + assertHasFix(FixKind.CREATE_LOCAL_VARIABLE, '''
|
| +typedef MY_FUNCTION(int p);
|
| +foo(MY_FUNCTION f) {}
|
| +main() {
|
| + MY_FUNCTION bar;
|
| + foo(bar);
|
| +}
|
| +''');
|
| + }
|
| +
|
| + void test_createLocalVariable_functionType_synthetic() {
|
| + _indexTestUnit('''
|
| +foo(f(int p)) {}
|
| +main() {
|
| + foo(bar);
|
| +}
|
| +''');
|
| + assertNoFix(FixKind.CREATE_LOCAL_VARIABLE);
|
| + }
|
| +
|
| void test_createLocalVariable_read_typeAssignment() {
|
| _indexTestUnit('''
|
| main() {
|
|
|