Sha256: 0e3aa401c8ba4150a3621439576626557506029051f68046076e340a2ff2f202
Contents?: true
Size: 782 Bytes
Versions: 9
Compression:
Stored size: 782 Bytes
Contents
import React from 'react'; import { Provider } from 'react-redux'; import { shallow } from '@theforeman/test'; import { statisticsProps } from './StatisticsPage/StatisticsPage.fixtures'; import Routes from './routes'; describe('ForemanPluginTemplateRoutes', () => { it('should create routes', () => { Object.entries(Routes).forEach(([key, Route]) => { const store = { subscribe: jest.fn(), dispatch: jest.fn(), getState: () => statisticsProps, }; const RouteComponent = Route.component; const component = shallow( <Provider store={store}> <RouteComponent history={{}} some="props" /> </Provider> ); Route.renderResult = component; }); expect(Routes).toMatchSnapshot(); }); });
Version data entries
9 entries across 9 versions & 1 rubygems