August 2017
Beginner
374 pages
10h 41m
English
After setting up our initial state, we can dispatch any actions by passing them to the reducer function:
test('setFilter action should change filter state', () => {
const category = 'test' const action = setFilter(category)
state = filterReducer(state, action)
expect(state).toBe(category)})
Read now
Unlock full access