state_notifier_test library
Support for doing something awesome.
More dartdocs go here.
Functions
-
stateNotifierTest<
SN extends StateNotifier< (State> , State>String description, {required FutureOr actions(SN stateNotifier), FutureOr< void> setUp()?, FutureOr<void> verify(SN stateNotifier)?, FutureOr<void> tearDown()?, required List<State> expect(), Iterable<State> seed()?, int skip = 0, required SN build(), dynamic errors()?, bool expectInitialState = false}) → void -
Creates a new
stateNotifier
-specific test case with the givendescription
. stateNotifierTest will handle asserting that thestateNotifier
emits theexpect
ed states (in order) afteraction
is executed. stateNotifierTest also handles ensuring that no additional states are emitted by closing thestateNotifier
stream before evaluating theexpect
ation. -
testNotifier<
SN extends StateNotifier< (State> , State>{required FutureOr actions(SN stateNotifier), required List< State> expect(), required SN build(), Iterable<State> seed()?, FutureOr<void> verify(SN stateNotifier)?, FutureOr<void> tearDown()?, dynamic errors()?, FutureOr<void> setUp()?, required int skip, bool expectInitialState = false}) → Future<void> - Internal stateNotifierTest runner which is only visible for testing. This should never be used directly -- please use stateNotifierTest instead.