(
initialState: PrivateAppState<UserData>,
actions: ((currentState: PrivateAppState<UserData>) => PuckAction)[]
)
| 158 | beforeEach(beforeEachFn); |
| 159 | |
| 160 | const executeSequence = ( |
| 161 | initialState: PrivateAppState<UserData>, |
| 162 | actions: ((currentState: PrivateAppState<UserData>) => PuckAction)[] |
| 163 | ) => { |
| 164 | let currentState: PrivateAppState<UserData> = initialState; |
| 165 | |
| 166 | actions.forEach((actionFn) => { |
| 167 | const action = actionFn(currentState); |
| 168 | |
| 169 | currentState = _reducer( |
| 170 | currentState, |
| 171 | action |
| 172 | ) as PrivateAppState<UserData>; |
| 173 | }); |
| 174 | |
| 175 | return currentState; |
| 176 | }; |
| 177 | |
| 178 | const reducer = (state: PrivateAppState, action: PuckAction) => |
| 179 | _reducer(state, action); |
no outgoing calls
no test coverage detected