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

Unified Diff: tests/compiler/dart2js/simple_inferrer_closure_test.dart

Issue 17759007: First pass at asynchronous input loading in dart2js. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Remove withCurrentElementAsync Created 7 years, 5 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 side-by-side diff with in-line comments
Download patch
Index: tests/compiler/dart2js/simple_inferrer_closure_test.dart
diff --git a/tests/compiler/dart2js/simple_inferrer_closure_test.dart b/tests/compiler/dart2js/simple_inferrer_closure_test.dart
index 6c6e1c37b5cd2b396e8177fc67af10c51ef9a343..3fb3ae5fd7dcdc38323408ef2d440cd1a254b6de 100644
--- a/tests/compiler/dart2js/simple_inferrer_closure_test.dart
+++ b/tests/compiler/dart2js/simple_inferrer_closure_test.dart
@@ -97,22 +97,23 @@ main() {
void main() {
Uri uri = new Uri(scheme: 'source');
var compiler = compilerFor(TEST, uri);
- compiler.runCompiler(uri);
- var typesInferrer = compiler.typesTask.typesInferrer;
+ compiler.runCompiler(uri).then((_) {
+ var typesInferrer = compiler.typesTask.typesInferrer;
- checkReturn(String name, type) {
- var element = findElement(compiler, name);
- Expect.equals(type,
- typesInferrer.getReturnTypeOfElement(element).simplify(compiler));
- }
+ checkReturn(String name, type) {
+ var element = findElement(compiler, name);
+ Expect.equals(type,
+ typesInferrer.getReturnTypeOfElement(element).simplify(compiler));
+ }
- checkReturn('returnInt1', compiler.typesTask.intType);
- checkReturn('returnInt2', compiler.typesTask.intType.nullable());
- checkReturn('returnInt3', compiler.typesTask.intType);
- checkReturn('returnInt4', compiler.typesTask.intType);
+ checkReturn('returnInt1', compiler.typesTask.intType);
+ checkReturn('returnInt2', compiler.typesTask.intType.nullable());
+ checkReturn('returnInt3', compiler.typesTask.intType);
+ checkReturn('returnInt4', compiler.typesTask.intType);
- checkReturn('returnDyn1', compiler.typesTask.dynamicType);
- checkReturn('returnDyn2', compiler.typesTask.dynamicType);
- checkReturn('returnDyn3', compiler.typesTask.dynamicType);
- checkReturn('returnNum1', compiler.typesTask.numType);
+ checkReturn('returnDyn1', compiler.typesTask.dynamicType);
+ checkReturn('returnDyn2', compiler.typesTask.dynamicType);
+ checkReturn('returnDyn3', compiler.typesTask.dynamicType);
+ checkReturn('returnNum1', compiler.typesTask.numType);
+ });
}

Powered by Google App Engine
This is Rietveld 408576698