| Index: pkg/analyzer/test/src/summary/resynthesize_ast_test.dart
|
| diff --git a/pkg/analyzer/test/src/summary/resynthesize_ast_test.dart b/pkg/analyzer/test/src/summary/resynthesize_ast_test.dart
|
| index dbe650de42c81afc0d0d34b467bcd8526f59ebd2..0de7edf4409406cb98fdb8f3b285de33fa44ee0c 100644
|
| --- a/pkg/analyzer/test/src/summary/resynthesize_ast_test.dart
|
| +++ b/pkg/analyzer/test/src/summary/resynthesize_ast_test.dart
|
| @@ -245,6 +245,41 @@ var d = foo.bar;
|
| ''');
|
| }
|
|
|
| + void test_infer_extractProperty_getter_sequence() {
|
| + var unit = checkFile(r'''
|
| +class A {
|
| + B b = new B();
|
| +}
|
| +class B {
|
| + C c = new C();
|
| +}
|
| +class C {
|
| + int d;
|
| +}
|
| +var a = new A();
|
| +var v = a.b.c.d;
|
| + ''');
|
| + expect(unit.topLevelVariables[1].type.toString(), 'int');
|
| + }
|
| +
|
| +
|
| + void test_infer_extractProperty_getter_sequence_generic() {
|
| + var unit = checkFile(r'''
|
| +class A<T> {
|
| + B<T> b = new B<T>();
|
| +}
|
| +class B<K> {
|
| + C<List<K>, int> c = new C<List<K>, int>();
|
| +}
|
| +class C<K, V> {
|
| + Map<K, V> d;
|
| +}
|
| +var a = new A<double>();
|
| +var v = a.b.c.d;
|
| + ''');
|
| + expect(unit.topLevelVariables[1].type.toString(), 'Map<List<double>, int>');
|
| + }
|
| +
|
| void test_infer_extractProperty_method() {
|
| checkFile(r'''
|
| var a = 1.round;
|
|
|