diff --git a/tests/e2e_tests/integration/03-files.spec.ts b/tests/e2e_tests/integration/03-files.spec.ts index c429c7402d..cab154b72a 100644 --- a/tests/e2e_tests/integration/03-files.spec.ts +++ b/tests/e2e_tests/integration/03-files.spec.ts @@ -125,7 +125,7 @@ test.describe('Files', () => { await page.getByPlaceholder(/select tags/i).fill('foo,'); const releasesNote = await page.getByText(/There are no Releases*/i); releasesNote.waitFor({ timeout: timeouts.default }); - expect(await releasesNote.isVisible()).toBeTruthy(); + await page.getByText(/mender-demo-artifact*/i).waitFor({ timeout: timeouts.default, state: 'detached' }); await page.getByText(/Clear filter/i).click(); await page.waitForSelector('text=/mender-demo-artifact*/i'); expect(await page.getByText(releaseTag.toLowerCase()).isVisible()).toBeTruthy(); diff --git a/tests/e2e_tests/integration/05-deviceDetails.spec.ts b/tests/e2e_tests/integration/05-deviceDetails.spec.ts index 2b62fbf7b1..cf7c47da3c 100644 --- a/tests/e2e_tests/integration/05-deviceDetails.spec.ts +++ b/tests/e2e_tests/integration/05-deviceDetails.spec.ts @@ -60,9 +60,9 @@ test.describe('Device details', () => { await page.getByLabel(/attribute/i).fill(rootfs); const nameInput = await page.getByLabel(/value/i); await nameInput.fill(demoDeviceName); + await page.waitForTimeout(timeouts.oneSecond); await nameInput.press('Enter'); - await page.waitForTimeout(timeouts.default); - expect(await page.getByRole('button', { name: `${rootfs} = ${demoDeviceName}` }).isVisible()).toBeTruthy(); + expect(await page.getByRole('button', { name: `${rootfs} = ${demoDeviceName}` }).isVisible({ timeout: timeouts.default })).toBeTruthy(); await page.waitForSelector('.deviceListItem'); expect(await page.getByText('1-1 of 1').isVisible()).toBeTruthy(); await page.getByText(/clear filter/i).click();