mirror of
https://github.com/storybookjs/storybook.git
synced 2025-04-07 07:21:17 +08:00
Use getByLabel rather than getByText
This commit is contained in:
parent
9077a3f07a
commit
b997f1eb03
@ -50,7 +50,11 @@ test.describe('save-from-controls', () => {
|
||||
await sbPage.panelContent().locator('[data-short-label="Unsaved changes"]').isVisible();
|
||||
|
||||
// clone the story
|
||||
await sbPage.panelContent().locator('button').getByText('Create new story').click();
|
||||
await sbPage
|
||||
.panelContent()
|
||||
.locator('button')
|
||||
.getByLabel(/Create new story/)
|
||||
.click();
|
||||
|
||||
const input = await sbPage.page.waitForSelector('[placeholder="Story export name"]');
|
||||
await input.fill('ClonedStory' + id);
|
||||
|
Loading…
x
Reference in New Issue
Block a user