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

Side by Side Diff: tests/compiler/dart2js/resolver_test.dart

Issue 1417323005: Rename Compiler.runCompiler -> runInternal. (Closed) Base URL: https://github.com/dart-lang/sdk.git@master
Patch Set: Created 5 years, 1 month 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) 2012, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2012, 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 'dart:async'; 5 import 'dart:async';
6 import 'dart:collection'; 6 import 'dart:collection';
7 7
8 import 'package:async_helper/async_helper.dart'; 8 import 'package:async_helper/async_helper.dart';
9 import 'package:expect/expect.dart'; 9 import 'package:expect/expect.dart';
10 import 'package:compiler/src/constants/expressions.dart'; 10 import 'package:compiler/src/constants/expressions.dart';
(...skipping 1056 matching lines...) Expand 10 before | Expand all | Expand 10 after
1067 List<String> result = <String>[]; 1067 List<String> result = <String>[];
1068 for (; !link.isEmpty; link = link.tail) result.add(link.head.toString()); 1068 for (; !link.isEmpty; link = link.tail) result.add(link.head.toString());
1069 result.sort((s1, s2) => s1.compareTo(s2)); 1069 result.sort((s1, s2) => s1.compareTo(s2));
1070 return result; 1070 return result;
1071 } 1071 }
1072 1072
1073 Future compileScript(String source) { 1073 Future compileScript(String source) {
1074 Uri uri = new Uri(scheme: 'source'); 1074 Uri uri = new Uri(scheme: 'source');
1075 MockCompiler compiler = compilerFor(source, uri); 1075 MockCompiler compiler = compilerFor(source, uri);
1076 compiler.diagnosticHandler = createHandler(compiler, source); 1076 compiler.diagnosticHandler = createHandler(compiler, source);
1077 return compiler.runCompiler(uri).then((_) { 1077 return compiler.run(uri).then((_) {
1078 return compiler; 1078 return compiler;
1079 }); 1079 });
1080 } 1080 }
1081 1081
1082 checkMemberResolved(compiler, className, memberName) { 1082 checkMemberResolved(compiler, className, memberName) {
1083 ClassElement cls = findElement(compiler, className); 1083 ClassElement cls = findElement(compiler, className);
1084 Element memberElement = cls.lookupLocalMember(memberName); 1084 Element memberElement = cls.lookupLocalMember(memberName);
1085 Expect.isNotNull(memberElement); 1085 Expect.isNotNull(memberElement);
1086 Expect.isTrue( 1086 Expect.isTrue(
1087 compiler.enqueuer.resolution.hasBeenProcessed(memberElement)); 1087 compiler.enqueuer.resolution.hasBeenProcessed(memberElement));
(...skipping 323 matching lines...) Expand 10 before | Expand all | Expand 10 after
1411 } 1411 }
1412 main() => A.m(); 1412 main() => A.m();
1413 ''', functionName: 'm'); 1413 ''', functionName: 'm');
1414 check(''' 1414 check('''
1415 class A { 1415 class A {
1416 m() => () => await - 3; 1416 m() => () => await - 3;
1417 } 1417 }
1418 main() => new A().m(); 1418 main() => new A().m();
1419 ''', className: 'A'); 1419 ''', className: 'A');
1420 } 1420 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698