Index: mojo/dart/test/simple_handle_watcher_test.dart |
diff --git a/mojo/dart/test/simple_handle_watcher_test.dart b/mojo/dart/test/simple_handle_watcher_test.dart |
index 9e7bfcd4aefaf091158ef187253be0aa3581e802..6ce9796b92a0c5e47b9d0ddb98ac2c65acc6c0e5 100644 |
--- a/mojo/dart/test/simple_handle_watcher_test.dart |
+++ b/mojo/dart/test/simple_handle_watcher_test.dart |
@@ -17,13 +17,13 @@ main() { |
var completer = new Completer(); |
int numEvents = 0; |
- handle.enableWriteEvents(); |
handle.listen((_) { |
numEvents++; |
handle.close(); |
}, onDone: () { |
completer.complete(numEvents); |
}); |
+ handle.enableWriteEvents(); |
completer.future.then((int numEvents) { |
assert(numEvents ==1); |