Skip to content

Commit 95a1e11

Browse files
committed
Update component.tsx
1 parent ddb62dd commit 95a1e11

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

cypress/support/component.tsx

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ import { mount } from 'cypress/react';
2222
import './commands';
2323
import { FrontendConfigContext } from '../../src/context/FrontendConfigContext';
2424
import { mockedFrontendConfig } from '../../src/utils/testing';
25-
25+
import { ToastProvider } from '../../src/context/ToastContext.tsx';
2626
// Augment the Cypress namespace to include type definitions for
2727
// your custom command.
2828
// Alternatively, can be defined in cypress/support/component.d.ts
@@ -38,10 +38,10 @@ declare global {
3838

3939

4040
Cypress.Commands.add('mount', (component, options) => {
41-
return mount(<ThemeProvider>
41+
return mount(<ThemeProvider> <ToastProvider>
4242
<FrontendConfigContext value={mockedFrontendConfig}>
4343
{component}
44-
</FrontendConfigContext>
44+
</FrontendConfigContext></ToastProvider>
4545
</ThemeProvider>, options);
4646
});
4747

0 commit comments

Comments
 (0)