maccounter
18 строк · 635.0 Байт
1import React from 'react'
2import { compareSnapshot } from '@testUtils/renderSnapshot'
3import WidgetContainer from '@components/Widget/WidgetContainer'
4import { Provider } from 'react-redux'
5import store from '@store/redux-store'
6import { WithChildren } from '@localTypes/BaseProps'
7
8describe('Widget', () => {
9const renderComponent = <WidgetContainer title="Last expenses" />
10const wrapper: React.FC<WithChildren> = ({ children }) => (
11<Provider store={store}>
12{children}
13</Provider>
14)
15
16// eslint-disable-next-line
17it('render Widget', () => compareSnapshot(renderComponent, wrapper))
18})
19