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

Side by Side Diff: pkg/analyzer/test/src/summary/linker_test.dart

Issue 1897513002: Fill out the implementation of synthetic getters/setters in the summary linker. (Closed) Base URL: git@github.com:dart-lang/sdk.git@master
Patch Set: Created 4 years, 8 months 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 unified diff | Download patch
OLDNEW
1 // Copyright (c) 2016, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2016, 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 import 'package:analyzer/src/summary/format.dart'; 5 import 'package:analyzer/src/summary/format.dart';
6 import 'package:analyzer/src/summary/link.dart'; 6 import 'package:analyzer/src/summary/link.dart';
7 import 'package:unittest/unittest.dart'; 7 import 'package:unittest/unittest.dart';
8 8
9 import '../../reflective_tests.dart'; 9 import '../../reflective_tests.dart';
10 import 'summarize_ast_test.dart'; 10 import 'summarize_ast_test.dart';
(...skipping 34 matching lines...) Expand 10 before | Expand all | Expand 10 after
45 } 45 }
46 class C<U> extends B<U> { 46 class C<U> extends B<U> {
47 var j; 47 var j;
48 } 48 }
49 '''); 49 ''');
50 LibraryElementForLink library = linker.getLibrary(linkerInputs.testDartUri); 50 LibraryElementForLink library = linker.getLibrary(linkerInputs.testDartUri);
51 library.libraryCycleForLink.ensureLinked(); 51 library.libraryCycleForLink.ensureLinked();
52 // No assertions--just make sure it doesn't crash. 52 // No assertions--just make sure it doesn't crash.
53 } 53 }
54 54
55 void test_baseClass_genericWithField() {
56 createLinker('''
57 class B<T> {
58 int i = 0;
59 }
60 class C<T> extends B<T> {
61 void f() {}
62 }
63 ''');
64 LibraryElementForLink library = linker.getLibrary(linkerInputs.testDartUri);
65 library.libraryCycleForLink.ensureLinked();
66 // No assertions--just make sure it doesn't crash.
67 }
68
55 void test_baseClass_genericWithGenericMethod() { 69 void test_baseClass_genericWithGenericMethod() {
56 createLinker(''' 70 createLinker('''
57 class B<T> { 71 class B<T> {
58 List<U> f<U>(U u) => null; 72 List<U> f<U>(U u) => null;
59 } 73 }
60 class C<V> extends B<V> { 74 class C<V> extends B<V> {
61 var j; 75 var j;
62 } 76 }
63 '''); 77 ''');
64 LibraryElementForLink library = linker.getLibrary(linkerInputs.testDartUri); 78 LibraryElementForLink library = linker.getLibrary(linkerInputs.testDartUri);
(...skipping 401 matching lines...) Expand 10 before | Expand all | Expand 10 after
466 class C extends B with I {} 480 class C extends B with I {}
467 class D extends C { 481 class D extends C {
468 void f() {} 482 void f() {}
469 } 483 }
470 '''); 484 ''');
471 LibraryElementForLink library = linker.getLibrary(linkerInputs.testDartUri); 485 LibraryElementForLink library = linker.getLibrary(linkerInputs.testDartUri);
472 library.libraryCycleForLink.ensureLinked(); 486 library.libraryCycleForLink.ensureLinked();
473 // No assertions--just make sure it doesn't crash. 487 // No assertions--just make sure it doesn't crash.
474 } 488 }
475 } 489 }
OLDNEW
« no previous file with comments | « pkg/analyzer/lib/src/summary/link.dart ('k') | pkg/analyzer/test/src/summary/resynthesize_ast_test.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698