storybookjs/storybook
[Bug]: Interactions - When step function is not awaited, it gets lost in debugger
开放
#21,519 创建于 2023年3月9日
addon: interactionsbughas workaroundhelp wantedsev:S4
仓库指标
- 星标
- (89,909 个星标)
- PR 合并指标
- (平均合并 7天 22小时) (30 天内合并 184 个 PR)
描述
Describe the bug

This happens if the play function looks like this:
play: async ({ canvasElement, step }) => {
const canvas = within(canvasElement);
const loginButton = await canvas.getByRole('button', {
name: /Log in/i,
});
await userEvent.click(loginButton);
// This should be awaited. If it's not, the panel bugs out.
step('click', async () => {
await userEvent.click(loginButton);
})
}
To Reproduce
https://stackblitz.com/edit/github-wmyzqk?file=src%2Fstories%2FPage.stories.ts&preset=node
System
No response
Additional context
No response