From c4a80262768aef0de6b6ccf7631ee343874bc71d Mon Sep 17 00:00:00 2001 From: Jose Olarte III Date: Mon, 12 Aug 2024 19:54:25 +0800 Subject: [PATCH] DONE: create 10 projects --- test-playwright/25-create-project-x10.spec.ts | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/test-playwright/25-create-project-x10.spec.ts b/test-playwright/25-create-project-x10.spec.ts index c7d11bd37..43f82db8a 100644 --- a/test-playwright/25-create-project-x10.spec.ts +++ b/test-playwright/25-create-project-x10.spec.ts @@ -19,7 +19,8 @@ function createUniqueStringsArray(count) { return stringsArray; } -test('Create 10 new projects, then search for them', async ({ page }) => { +test('Create 10 new projects', async ({ page }) => { + test.slow(); // Extend the test timeout const projectCount = 10; // Standard texts @@ -44,8 +45,8 @@ test('Create 10 new projects, then search for them', async ({ page }) => { // Import user 00 await importUser(page, '00'); - // Pause for 5 seconds - await page.waitForTimeout(5000); // I have to wait, otherwise the (+) button to add a new project doesn't appear + // Pause a bit + await page.waitForTimeout(3000); // I have to wait, otherwise the (+) button to add a new project doesn't appear // Create new projects for (let i = 0; i < projectCount; i++) { @@ -58,6 +59,7 @@ test('Create 10 new projects, then search for them', async ({ page }) => { await page.getByPlaceholder('Start Date').fill('2025-12-01'); await page.getByPlaceholder('Start Time').fill('12:00'); await page.getByRole('button', { name: 'Save Project' }).click(); + await page.waitForTimeout(1000); // Compensate for delay in loading Idea Name heading // Check texts await expect(page.locator('h2')).toContainText(finalTitles[i]);