| Index: runtime/observatory/tests/service/test_helper.dart
|
| diff --git a/runtime/observatory/tests/service/test_helper.dart b/runtime/observatory/tests/service/test_helper.dart
|
| index 1d2ea9d54dec24b1ab974940b3970138cb865a76..0e8b6e932af424b757e26dcf039252d1c5dd47f0 100644
|
| --- a/runtime/observatory/tests/service/test_helper.dart
|
| +++ b/runtime/observatory/tests/service/test_helper.dart
|
| @@ -310,7 +310,14 @@ class _ServiceTesterRunner {
|
| await process.requestExit();
|
| }, onError: (e, st) {
|
| process.requestExit();
|
| - if (!_isWebSocketDisconnect(e)) {
|
| + // TODO: remove this workaround.
|
| + // This is necessary due to non awaited operations.
|
| + // E.G. object.dart (398~402)
|
| + // When an exception is thrown inside a test (directly or via await) the
|
| + // stacktrace is non-null and shows where the exception has been thrown.
|
| + // If vice versa the exception is due to an error in a non-awaited
|
| + // Future the stacktrace is null.
|
| + if (st != null || !_isWebSocketDisconnect(e)) {
|
| print('Unexpected exception in service tests: $e $st');
|
| throw e;
|
| }
|
|
|