diff options
author | Shin'ya Ueoka <ueokande@i-beam.org> | 2017-10-09 17:35:10 +0900 |
---|---|---|
committer | GitHub <noreply@github.com> | 2017-10-09 17:35:10 +0900 |
commit | 447466808f484d4baa6b285f2dbcaf1920db5498 (patch) | |
tree | aba110eb78b4ce3eb6cefb8100f167e17a23fcc3 /test/settings/reducers/setting.test.js | |
parent | 892eb8a6a6d9080213f461f19a8b8435a6482237 (diff) | |
parent | 805d1395fc869235f079438b5b4884a521c0230e (diff) |
Merge pull request #27 from ueokande/react-settings
Use React in settings
Diffstat (limited to 'test/settings/reducers/setting.test.js')
-rw-r--r-- | test/settings/reducers/setting.test.js | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/test/settings/reducers/setting.test.js b/test/settings/reducers/setting.test.js index 0e84247..3468d4b 100644 --- a/test/settings/reducers/setting.test.js +++ b/test/settings/reducers/setting.test.js @@ -5,18 +5,18 @@ import settingReducer from 'settings/reducers/setting'; describe("setting reducer", () => { it('return the initial state', () => { let state = settingReducer(undefined, {}); - expect(state).to.have.deep.property('settings', {}); + expect(state).to.have.deep.property('json', ''); + expect(state).to.have.deep.property('value', {}); }); it('return next state for SETTING_SET_SETTINGS', () => { let action = { type: actions.SETTING_SET_SETTINGS, - settings: { value1: 'hello', value2: 'world' }, + json: '{ "key": "value" }', + value: { key: 123 }, }; let state = settingReducer(undefined, action); - expect(state).to.have.deep.property('settings', { - value1: 'hello', - value2: 'world', - }); + expect(state).to.have.deep.property('json', '{ "key": "value" }'); + expect(state).to.have.deep.property('value', { key: 123 }); }); }); |