From: angular.dart/lib/mock/zone.dart : microLeap, line 50
microLeap() {
while (_asyncQueue.isNotEmpty) {
// copy the queue as it may change.
var toRun = new List.from(_asyncQueue);
_asyncQueue.clear();
// TODO: Support the case where multiple exceptions are thrown.
// e.g. with a throwNextException() method.
assert(_asyncErrors.isEmpty);
toRun.forEach((fn) => fn());
if (_asyncErrors.isNotEmpty) {
var e = _asyncErrors.removeAt(0);
throw ['Async error', e[0], e[1]];
}
}
}
When run in checked mode, assert(_asyncErrors.isEmpty) halts execution and the errors from _asyncErrors are never re-thrown which makes debugging difficult. Is this assertion necessary?
From: angular.dart/lib/mock/zone.dart : microLeap, line 50
When run in checked mode,
assert(_asyncErrors.isEmpty)
halts execution and the errors from_asyncErrors
are never re-thrown which makes debugging difficult. Is this assertion necessary?