Index: tests/compiler/dart2js/simple_inferrer_final_field3_test.dart |
diff --git a/tests/compiler/dart2js/simple_inferrer_final_field3_test.dart b/tests/compiler/dart2js/simple_inferrer_final_field3_test.dart |
index a4a4e1f2eb6f023404e0a3ce73e66179984b89f0..9c76b761fcb06ce1045cc11181c835ac16ae8c70 100644 |
--- a/tests/compiler/dart2js/simple_inferrer_final_field3_test.dart |
+++ b/tests/compiler/dart2js/simple_inferrer_final_field3_test.dart |
@@ -5,6 +5,7 @@ |
// Test that we are analyzing field parameters correctly. |
import 'package:expect/expect.dart'; |
+import "package:async_helper/async_helper.dart"; |
import 'compiler_helper.dart'; |
import 'parser_helper.dart'; |
@@ -25,16 +26,17 @@ main() { |
void main() { |
Uri uri = new Uri(scheme: 'source'); |
var compiler = compilerFor(TEST, uri); |
- compiler.runCompiler(uri); |
- var typesInferrer = compiler.typesTask.typesInferrer; |
- |
- checkFieldTypeInClass(String className, String fieldName, type) { |
- var cls = findElement(compiler, className); |
- var element = cls.lookupLocalMember(buildSourceString(fieldName)); |
- Expect.equals(type, |
- typesInferrer.getTypeOfElement(element).simplify(compiler)); |
- } |
- |
- checkFieldTypeInClass('A', 'dynamicField', |
- findTypeMask(compiler, 'Interceptor', 'nonNullSubclass')); |
+ asyncTest(() => compiler.runCompiler(uri).then((_) { |
+ var typesInferrer = compiler.typesTask.typesInferrer; |
+ |
+ checkFieldTypeInClass(String className, String fieldName, type) { |
+ var cls = findElement(compiler, className); |
+ var element = cls.lookupLocalMember(buildSourceString(fieldName)); |
+ Expect.equals(type, |
+ typesInferrer.getTypeOfElement(element).simplify(compiler)); |
+ } |
+ |
+ checkFieldTypeInClass('A', 'dynamicField', |
+ findTypeMask(compiler, 'Interceptor', 'nonNullSubclass')); |
+ })); |
} |