fix load and create safe test: remove memoryHistory because it doesnt update window

This commit is contained in:
Mikhail Mikheev 2019-06-04 15:57:24 +04:00
parent bf3ade5209
commit 4c5143f228
2 changed files with 2 additions and 3 deletions

View File

@ -1,5 +1,5 @@
// @flow // @flow
import { createBrowserHistory, createMemoryHistory } from 'history' import { createBrowserHistory } from 'history'
import { connectRouter, routerMiddleware } from 'connected-react-router' import { connectRouter, routerMiddleware } from 'connected-react-router'
import { import {
combineReducers, createStore, applyMiddleware, compose, type Reducer, type Store, combineReducers, createStore, applyMiddleware, compose, type Reducer, type Store,
@ -14,7 +14,7 @@ import transactions, {
TRANSACTIONS_REDUCER_ID, TRANSACTIONS_REDUCER_ID,
} from '~/routes/safe/store/reducer/transactions' } from '~/routes/safe/store/reducer/transactions'
export const history = process.env.NODE_ENV === 'test' ? createMemoryHistory() : createBrowserHistory() export const history = createBrowserHistory()
// eslint-disable-next-line // eslint-disable-next-line
const composeEnhancers = window.__REDUX_DEVTOOLS_EXTENSION_COMPOSE__ || compose const composeEnhancers = window.__REDUX_DEVTOOLS_EXTENSION_COMPOSE__ || compose

View File

@ -58,7 +58,6 @@ describe('DOM > Feature > LOAD a safe', () => {
fireEvent.change(safeNameInput, { target: { value: 'A Safe To Load' } }) fireEvent.change(safeNameInput, { target: { value: 'A Safe To Load' } })
fireEvent.change(safeAddressInput, { target: { value: address } }) fireEvent.change(safeAddressInput, { target: { value: address } })
await sleep(400) await sleep(400)
// Click next // Click next
fireEvent.submit(form) fireEvent.submit(form)
await sleep(400) await sleep(400)