Last active
July 4, 2020 22:15
-
-
Save s-barrah/6d18ab92173dbbdf0642c040fd89c24c to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import * as React from 'react'; | |
import renderer from 'react-test-renderer'; | |
import theme from '../theme/project1/theme'; | |
import ThemeProvider from '../theme/ThemeProvider'; | |
export default function renderWithTheme(component: JSX.Element) { | |
return renderer.create(<ThemeProvider theme={theme}>{component}</ThemeProvider>); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment