Improve tests (#871)

This commit is contained in:
Charles Bochet
2023-07-24 00:57:56 -07:00
committed by GitHub
parent 2b885f2496
commit 07180af8c0
53 changed files with 432 additions and 251 deletions

View File

@ -194,7 +194,10 @@ export const EditRelation: Story = {
mockedPeopleData[1].company.name,
);
await userEvent.click(secondRowCompanyCell);
await userEvent.click(
secondRowCompanyCell.parentNode?.parentNode?.parentNode
?.parentElement as HTMLElement,
);
});
await step('Type "Air" in relation picker', async () => {
@ -244,7 +247,10 @@ export const SelectRelationWithKeys: Story = {
);
await sleep(25);
await userEvent.click(firstRowCompanyCell);
await userEvent.click(
firstRowCompanyCell.parentNode?.parentNode?.parentNode
?.parentElement as HTMLElement,
);
firstRowCompanyCell = await canvas.findByText(
mockedPeopleData[0].company.name,
);