dispatchAndWaitGetInfo method
Dispatches action
, and then waits until it finishes.
Returns the info after the action finishes. Ignores other actions.
Example use:
var action = MyAction(); await storeTester.dispatchAndWait(action);
Note, this is the same as doing:
var action = MyAction(); storeTester.dispatch(action); await storeTester.wait(action);
Implementation
Future<TestInfo<St>> dispatchAndWaitGetInfo(ReduxAction<St> action) {
store.dispatch(action);
return waitUntilAction(action);
}