Index: runtime/observatory/tests/service/pause_on_start_and_exit_test.dart |
diff --git a/runtime/observatory/tests/service/pause_on_start_and_exit_test.dart b/runtime/observatory/tests/service/pause_on_start_and_exit_test.dart |
index b7f7935be55891753eda0c9742e49c7f9b9e5368..7c63e9d609201d00151199497a338f92be0aa690 100644 |
--- a/runtime/observatory/tests/service/pause_on_start_and_exit_test.dart |
+++ b/runtime/observatory/tests/service/pause_on_start_and_exit_test.dart |
@@ -4,6 +4,7 @@ |
// VMOptions=--error_on_bad_type --error_on_bad_override |
import 'package:observatory/service_io.dart'; |
+import 'package:unittest/unittest.dart'; |
import 'test_helper.dart'; |
import 'dart:async'; |
@@ -33,6 +34,15 @@ var tests = [ |
await completer.future; |
} |
+ // Grab the timestamp. |
+ var pausetime1 = isolate.pauseEvent.timestamp; |
+ expect(pausetime1, isNotNull); |
+ // Reload the isolate. |
+ await isolate.reload(); |
+ // Verify that it is the same. |
+ expect(pausetime1.millisecondsSinceEpoch, |
+ equals(isolate.pauseEvent.timestamp.millisecondsSinceEpoch)); |
+ |
completer = new Completer(); |
stream = await isolate.vm.getEventStream(VM.kDebugStream); |
subscription = stream.listen((ServiceEvent event) { |
@@ -48,6 +58,17 @@ var tests = [ |
// Wait for the isolate to hit PauseExit. |
await completer.future; |
+ |
+ // Grab the timestamp. |
+ var pausetime2 = isolate.pauseEvent.timestamp; |
+ expect(pausetime2, isNotNull); |
+ // Reload the isolate. |
+ await isolate.reload(); |
+ // Verify that it is the same. |
+ expect(pausetime2.millisecondsSinceEpoch, |
+ equals(isolate.pauseEvent.timestamp.millisecondsSinceEpoch)); |
+ expect(pausetime2.millisecondsSinceEpoch, |
+ greaterThan(pausetime1.millisecondsSinceEpoch)); |
}, |
]; |