zonedExpect function

void zonedExpect(
  1. dynamic actual,
  2. dynamic matcher, {
  3. String? reason,
})

Calls expect in package:test/test.dart in the zone stored in storeZone.

Useful for expectations in blocks called in other zones.

Implementation

void zonedExpect(actual, matcher, {String? reason}) {
  validateZone();

  return _zone!.run(() {
    expect(actual, matcher, reason: reason);
  });
}