| Index: lib/src/backend/invoker.dart
|
| diff --git a/lib/src/backend/invoker.dart b/lib/src/backend/invoker.dart
|
| index 221c52a06a3667638c1ec85ea2efda388906d061..fbf7f20176cc825c2476944b90d52ef9962f2a0f 100644
|
| --- a/lib/src/backend/invoker.dart
|
| +++ b/lib/src/backend/invoker.dart
|
| @@ -120,6 +120,13 @@ class Invoker {
|
| void removeOutstandingCallback() =>
|
| _outstandingCallbacks.removeOutstandingCallback();
|
|
|
| + /// Removes all outstanding callbacks, for example when an error occurs.
|
| + ///
|
| + /// Future calls to [addOutstandingCallback] and [removeOutstandingCallback]
|
| + /// will be ignored.
|
| + void removeAllOutstandingCallbacks() =>
|
| + _outstandingCallbacks.removeAllOutstandingCallbacks();
|
| +
|
| /// Runs [fn] and returns once all (registered) outstanding callbacks it
|
| /// transitively invokes have completed.
|
| ///
|
| @@ -160,7 +167,7 @@ class Invoker {
|
| }
|
|
|
| _controller.addError(error, stackTrace);
|
| - _outstandingCallbacks.removeAllOutstandingCallbacks();
|
| + removeAllOutstandingCallbacks();
|
|
|
| // If a test was marked as success but then had an error, that indicates
|
| // that it was poorly-written and could be flaky.
|
|
|