Replies: 2 comments
-
I'd be interested in this too, but looking at the source code of |
Beta Was this translation helpful? Give feedback.
0 replies
-
From the documentation https://storybook.js.org/docs/essentials/interactions Use // Form.stories.ts|tsx
...
export const Submitted: Story = {
play: async ({ args, canvasElement, step }) => {
const canvas = within(canvasElement);
await step('Enter credentials', async () => {
await userEvent.type(canvas.getByTestId('email'), '[email protected]');
});
await step('Submit form', async () => {
await userEvent.click(canvas.getByRole('button'));
});
},
}; |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
How to set test name at addon-interactions?
Is it available in beta version?
like this post. thanks
https://storybook.js.org/blog/interaction-testing-sneak-peek/
Beta Was this translation helpful? Give feedback.
All reactions