You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
24 lines
838 B
24 lines
838 B
2 years ago
|
import configStore from '../src/redux/CreateStore';
|
||
|
import {navReducer} from '../src/redux/reducers/NavReducer';
|
||
|
import {systemReducer} from '../src/redux/reducers/SystemReducer';
|
||
|
import rootReducer from '../src/redux/reducers/RootReducer';
|
||
|
import { APP_INIT } from '../src/redux/types/SystemTypes';
|
||
|
|
||
|
test('configures redux store', () => {
|
||
|
const configgedStore = configStore;
|
||
|
expect(configgedStore).toEqual(expect.anything());
|
||
|
})
|
||
|
|
||
|
test('rootReducer constructs', () => {
|
||
|
expect(rootReducer).toEqual(expect.anything());
|
||
|
})
|
||
|
|
||
|
test('navReducer response to app-init', () => {
|
||
|
let nextState = navReducer({}, {type: APP_INIT});
|
||
|
expect(nextState).toEqual({});
|
||
|
})
|
||
|
|
||
|
test('systemReducer response to app-init', () => {
|
||
|
let nextState = systemReducer.system({}, {type: APP_INIT, system: {value: 0}});
|
||
|
expect(nextState.value).toEqual(0);
|
||
|
})
|