From c6385e81c85447dda96e5c467de182c0ea40fcc9 Mon Sep 17 00:00:00 2001 From: Matthew Shao Date: Mon, 7 Aug 2017 11:08:19 +0800 Subject: [web] Update tests to ensure they won't be disturbed by static mode --- .../js/__tests__/components/Header/FlowMenuSpec.js | 1 + .../__tests__/components/Header/OptionMenuSpec.js | 1 + .../Header/__snapshots__/OptionMenuSpec.js.snap | 30 ++++++++++++---------- 3 files changed, 19 insertions(+), 13 deletions(-) (limited to 'web/src/js') diff --git a/web/src/js/__tests__/components/Header/FlowMenuSpec.js b/web/src/js/__tests__/components/Header/FlowMenuSpec.js index 1278d8ee..03b0f59d 100644 --- a/web/src/js/__tests__/components/Header/FlowMenuSpec.js +++ b/web/src/js/__tests__/components/Header/FlowMenuSpec.js @@ -7,6 +7,7 @@ import { TFlow, TStore }from '../../ducks/tutils' import { MessageUtils } from "../../../flow/utils" import { Provider } from 'react-redux' +global.MITMWEB_STATIC = false describe('FlowMenu Component', () => { let actions = { diff --git a/web/src/js/__tests__/components/Header/OptionMenuSpec.js b/web/src/js/__tests__/components/Header/OptionMenuSpec.js index b84fce6e..729f42f2 100644 --- a/web/src/js/__tests__/components/Header/OptionMenuSpec.js +++ b/web/src/js/__tests__/components/Header/OptionMenuSpec.js @@ -4,6 +4,7 @@ import { Provider } from 'react-redux' import OptionMenu from '../../../components/Header/OptionMenu' import { TStore } from '../../ducks/tutils' +global.MITMWEB_STATIC = false describe('OptionMenu Component', () => { it('should render correctly', () => { diff --git a/web/src/js/__tests__/components/Header/__snapshots__/OptionMenuSpec.js.snap b/web/src/js/__tests__/components/Header/__snapshots__/OptionMenuSpec.js.snap index 9299e69f..ec305862 100644 --- a/web/src/js/__tests__/components/Header/__snapshots__/OptionMenuSpec.js.snap +++ b/web/src/js/__tests__/components/Header/__snapshots__/OptionMenuSpec.js.snap @@ -107,20 +107,24 @@ exports[`OptionMenu Component should render correctly 1`] = ` className="menu-content" >
- +
+ +