Update context passed in Shortcuts.test.tsx and ShortcutItem.test.tsx
Signed-off-by: hiba-aldalaty <hibaaldalaty@gmail.com>
This commit is contained in:
@@ -37,7 +37,9 @@ describe('ShortcutItem', () => {
|
||||
|
||||
it('displays the shortcut', async () => {
|
||||
await renderInTestApp(
|
||||
<SidebarContext.Provider value={{ isOpen: true, setIsOpen: () => {} }}>
|
||||
<SidebarContext.Provider
|
||||
value={{ isOpen: true, handleOpen: () => {}, handleClose: () => {} }}
|
||||
>
|
||||
<ShortcutItem api={api} shortcut={shortcut} />
|
||||
</SidebarContext.Provider>,
|
||||
);
|
||||
|
||||
@@ -30,7 +30,9 @@ const apis = ApiRegistry.from([
|
||||
describe('Shortcuts', () => {
|
||||
it('displays an add button', async () => {
|
||||
await renderInTestApp(
|
||||
<SidebarContext.Provider value={{ isOpen: true, setIsOpen: () => {} }}>
|
||||
<SidebarContext.Provider
|
||||
value={{ isOpen: true, handleOpen: () => {}, handleClose: () => {} }}
|
||||
>
|
||||
<ApiProvider apis={apis}>
|
||||
<Shortcuts />
|
||||
</ApiProvider>
|
||||
|
||||
Reference in New Issue
Block a user