assertDisconnected method

void assertDisconnected()

Assert that the fake driver is currently disconnected.

Throws AssertionError if the driver is connected.

Implementation

void assertDisconnected() {
  if (_driver._connected) {
    throw AssertionError(
      'Expected the broadcast driver to be disconnected but it was connected.',
    );
  }
}