Index: tests/html/custom/attribute_changed_callback_test.dart |
diff --git a/tests/html/custom/attribute_changed_callback_test.dart b/tests/html/custom/attribute_changed_callback_test.dart |
index 71ffaec3fbc3bb06b4d8f32af34b26b49b2b70c1..07abbf3e0af10637bb38f6d2d5c42cf131670bc3 100644 |
--- a/tests/html/custom/attribute_changed_callback_test.dart |
+++ b/tests/html/custom/attribute_changed_callback_test.dart |
@@ -4,6 +4,7 @@ |
library attribute_changed_callback_test; |
+import 'dart:async'; |
import 'dart:html'; |
import 'dart:js' as js; |
import 'package:unittest/html_individual_config.dart'; |
@@ -90,11 +91,15 @@ main() { |
var b = new B(); |
b.id = 'x'; |
- expect(B.invocations, ['created', 'id: null => x']); |
- |
- B.invocations = []; |
- b.attributes.remove('id'); |
- expect(B.invocations, ['id: x => null']); |
+ |
+ return new Future.delayed(new Duration(milliseconds: 1)) |
+ .then((_) => expect(B.invocations, ['created', 'id: null => x'])) |
+ .then((_) { |
+ B.invocations = []; |
+ b.attributes.remove('id'); |
+ }) |
+ .then((_) => new Future.delayed(new Duration(milliseconds: 1))) |
+ .then((_) => expect(B.invocations, ['id: x => null'])); |
}); |
}); |