Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
it(`should display children on mobile`, () => {
useBreakpoints.mockReturnValue({ isMobile: true })
expect(
shallow(content).getElement()
).toMatchSnapshot()
})
const setup = options => {
const { props, breakpoints } = options
useBreakpoints.mockReturnValue(breakpoints)
return mount(
,
{
context: {
router: {
...mockRouter,
getCurrentLocation: () => ({
pathname: '/'
})
}
},
childContextTypes: {
router: PropTypes.object
}