(e2e) fix flakiness

Some tests were getting very flaky due to previous
tests updates. This should fix it.
This commit is contained in:
Anthony LC
2025-09-18 11:28:20 +02:00
parent 2dc1e07b42
commit e4aa85be83
2 changed files with 9 additions and 4 deletions

View File

@@ -438,7 +438,9 @@ test.describe('Doc Header', () => {
// Pin
await page.getByText('push_pin').click();
await page.getByLabel('Open the document options').click();
await page
.getByRole('button', { name: 'Open the document options' })
.click();
await expect(page.getByText('Unpin')).toBeVisible();
await page.goto('/');

View File

@@ -113,9 +113,12 @@ export const connectOtherUserToDoc = async (
const otherPage = await otherContext.newPage();
await otherPage.goto(docUrl);
await otherPage.getByRole('button', { name: 'Login' }).click({
timeout: 15000,
});
await otherPage
.getByRole('main', { name: 'Main content' })
.getByLabel('Login')
.click({
timeout: 15000,
});
await keyCloakSignIn(otherPage, otherBrowserName, false);