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

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

Issue 2456803004: fixes #27586, prefer context type in generic inference (Closed)
Patch Set: fix Created 3 years, 9 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 library analyzer.test.src.summary.resynthesize_ast_test; 5 library analyzer.test.src.summary.resynthesize_ast_test;
6 6
7 import 'dart:async'; 7 import 'dart:async';
8 8
9 import 'package:analyzer/dart/ast/ast.dart'; 9 import 'package:analyzer/dart/ast/ast.dart';
10 import 'package:analyzer/dart/element/element.dart'; 10 import 'package:analyzer/dart/element/element.dart';
(...skipping 155 matching lines...) Expand 10 before | Expand all | Expand 10 after
166 variablesWithNotConstInitializers.add('a2'); 166 variablesWithNotConstInitializers.add('a2');
167 await super.test_canInferAlsoFromStaticAndInstanceFieldsFlagOn(); 167 await super.test_canInferAlsoFromStaticAndInstanceFieldsFlagOn();
168 } 168 }
169 169
170 @override 170 @override
171 @failingTest 171 @failingTest
172 test_circularReference_viaClosures_initializerTypes() async { 172 test_circularReference_viaClosures_initializerTypes() async {
173 await super.test_circularReference_viaClosures_initializerTypes(); 173 await super.test_circularReference_viaClosures_initializerTypes();
174 } 174 }
175 175
176 @override
177 @failingTest
178 test_blockBodiedLambdas_noReturn_topLevel() =>
179 super.test_blockBodiedLambdas_noReturn_topLevel();
180
181 @failingTest
182 @override
183 test_listLiteralsCanInferNull_topLevel() =>
184 super.test_listLiteralsCanInferNull_topLevel();
185
186 @failingTest
187 @override
188 test_mapLiteralsCanInferNull_topLevel() =>
189 super.test_mapLiteralsCanInferNull_topLevel();
190
176 test_infer_extractIndex_custom() async { 191 test_infer_extractIndex_custom() async {
177 var unit = await checkFileElement(''' 192 var unit = await checkFileElement('''
178 class A { 193 class A {
179 String operator [](_) => null; 194 String operator [](_) => null;
180 } 195 }
181 var a = new A(); 196 var a = new A();
182 var b = a[0]; 197 var b = a[0];
183 '''); 198 ''');
184 expect(unit.topLevelVariables[1].type.toString(), 'String'); 199 expect(unit.topLevelVariables[1].type.toString(), 'String');
185 } 200 }
(...skipping 738 matching lines...) Expand 10 before | Expand all | Expand 10 after
924 939
925 @override 940 @override
926 AnalysisOptionsImpl createOptions() => 941 AnalysisOptionsImpl createOptions() =>
927 super.createOptions()..strongMode = isStrongMode; 942 super.createOptions()..strongMode = isStrongMode;
928 943
929 @override 944 @override
930 TestSummaryResynthesizer encodeDecodeLibrarySource(Source source) { 945 TestSummaryResynthesizer encodeDecodeLibrarySource(Source source) {
931 return _encodeLibrary(source); 946 return _encodeLibrary(source);
932 } 947 }
933 } 948 }
OLDNEW
« no previous file with comments | « pkg/analyzer/test/generated/type_system_test.dart ('k') | pkg/analyzer/test/src/task/strong/checker_test.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698