aboutsummaryrefslogtreecommitdiffstats
path: root/web/src/js/__tests__/ducks
diff options
context:
space:
mode:
authorMatthew Shao <me@matshao.com>2017-07-20 22:26:28 +0800
committerMatthew Shao <me@matshao.com>2017-07-20 22:26:28 +0800
commitcb73658dd43e01bdedd84aa31601887b19c106ca (patch)
treef557ba665efeb7ba27f0b9f0523b374ded8dbb4c /web/src/js/__tests__/ducks
parentf465f08c9ac302007b3aec6709a8e82d63c7ad65 (diff)
downloadmitmproxy-cb73658dd43e01bdedd84aa31601887b19c106ca.tar.gz
mitmproxy-cb73658dd43e01bdedd84aa31601887b19c106ca.tar.bz2
mitmproxy-cb73658dd43e01bdedd84aa31601887b19c106ca.zip
[web] Remove js/ducks/ui/option.js
Diffstat (limited to 'web/src/js/__tests__/ducks')
-rw-r--r--web/src/js/__tests__/ducks/ui/optionSpec.js39
1 files changed, 0 insertions, 39 deletions
diff --git a/web/src/js/__tests__/ducks/ui/optionSpec.js b/web/src/js/__tests__/ducks/ui/optionSpec.js
deleted file mode 100644
index 4b6b43cc..00000000
--- a/web/src/js/__tests__/ducks/ui/optionSpec.js
+++ /dev/null
@@ -1,39 +0,0 @@
-import reduceOption, * as optionActions from '../../../ducks/ui/option'
-
-describe('option reducer', () => {
-
- it('should return the initial state', () => {
- expect(reduceOption(undefined, {})).toEqual({})
- })
-
- let state = undefined
- it('should handle option update start', () => {
- state = reduceOption(undefined, {
- type: optionActions.OPTION_UPDATE_START, option: 'foo', value: 'bar'
- })
- expect(state).toEqual({
- foo: {
- error: false,
- isUpdating: true,
- value: 'bar'
- }
- })
- })
-
- it('should handle option update success', () => {
- expect(reduceOption(state, {
- type: optionActions.OPTION_UPDATE_SUCCESS, option: 'foo'
- })).toEqual({})
- })
-
- it('should handle option update error', () => {
- expect(reduceOption(undefined, {
- type: optionActions.OPTION_UPDATE_ERROR, option: 'foo', error: 'errorMsg'
- })).toEqual({
- foo: {
- error: 'errorMsg',
- isUpdating: false,
- }
- })
- })
-})