Index: tests/compiler/dart2js/concrete_type_inference_test.dart |
diff --git a/tests/compiler/dart2js/concrete_type_inference_test.dart b/tests/compiler/dart2js/concrete_type_inference_test.dart |
index 71d8488cba6a439e1ab23c7282a375e7623205b4..fefb7a67a1be395c1c28c4f56e7cca149830d801 100644 |
--- a/tests/compiler/dart2js/concrete_type_inference_test.dart |
+++ b/tests/compiler/dart2js/concrete_type_inference_test.dart |
@@ -2,17 +2,19 @@ |
// for details. All rights reserved. Use of this source code is governed by a |
// BSD-style license that can be found in the LICENSE file. |
+import 'dart:async'; |
import "package:expect/expect.dart"; |
import 'compiler_helper.dart'; |
import 'parser_helper.dart'; |
-void compileAndFind(String code, String name, |
+Future compileAndFind(String code, String name, |
check(compiler, element)) { |
Uri uri = new Uri(scheme: 'source'); |
- var compiler = compilerFor(code, uri); |
- compiler.runCompiler(uri); |
- var element = findElement(compiler, name); |
- return check(compiler, element); |
+ MockCompiler compiler = compilerFor(code, uri); |
+ compiler.runCompiler(uri).then((_) { |
+ var element = findElement(compiler, name); |
+ return check(compiler, element); |
+ }); |
} |
void checkPrintType(String expression, checkType(compiler, type)) { |