assertTesting function

void assertTesting()

UnitTestであることを保証する. 間違って呼び出さないようにするための保険.

Implementation

void assertTesting() {
  assert(
    _isFlutterTesting,
    'Invalid runtime',
  ); // Build phase check.
  check(
    _isFlutterTesting,
    () => 'Invalid runtime',
  ); // Runtime phase check.
}