Make react-test usable without styled-components
This commit is contained in:
parent
e86c8b9226
commit
12515eac74
@ -114,9 +114,15 @@ export class TestUtils {
|
||||
const component: TestContainer | null = await new Promise(resolve => {
|
||||
ReactDOM.render(
|
||||
<TestContainer ref={instance => resolve(instance)}>
|
||||
<ThemeProvider theme={TestUtils.defaultTheme}>
|
||||
{jsx}
|
||||
</ThemeProvider>
|
||||
{
|
||||
TestUtils.defaultTheme
|
||||
? (
|
||||
<ThemeProvider theme={TestUtils.defaultTheme}>
|
||||
{jsx}
|
||||
</ThemeProvider>
|
||||
)
|
||||
: jsx
|
||||
}
|
||||
</TestContainer>,
|
||||
$div,
|
||||
)
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user