diff --git a/code/lib/ui/src/components/sidebar/Menu.stories.tsx b/code/lib/ui/src/components/sidebar/Menu.stories.tsx index f73a5fe661e8..2968056caf6b 100644 --- a/code/lib/ui/src/components/sidebar/Menu.stories.tsx +++ b/code/lib/ui/src/components/sidebar/Menu.stories.tsx @@ -63,7 +63,7 @@ export const Expanded = () => { }; Expanded.play = async ({ canvasElement }) => { const canvas = within(canvasElement); - const menuButton = await canvas.getByRole('button'); + const menuButton = await canvas.findByRole('button'); await userEvent.click(menuButton); };