From 2e5a5b65fd622a659c1189f59bf10e634c9c3d30 Mon Sep 17 00:00:00 2001 From: Andreas Zerbst <73799582+andr317c@users.noreply.github.com> Date: Tue, 25 Feb 2025 14:06:52 +0100 Subject: [PATCH] V15 QA fixed flaky language tests (#18451) * Added wait for flaky test * Updated version --- .../package-lock.json | 17 +++++++++-------- tests/Umbraco.Tests.AcceptanceTest/package.json | 2 +- .../DefaultConfig/Dictionary/Dictionary.spec.ts | 3 +++ 3 files changed, 13 insertions(+), 9 deletions(-) diff --git a/tests/Umbraco.Tests.AcceptanceTest/package-lock.json b/tests/Umbraco.Tests.AcceptanceTest/package-lock.json index d0e3899ceb..0139e39172 100644 --- a/tests/Umbraco.Tests.AcceptanceTest/package-lock.json +++ b/tests/Umbraco.Tests.AcceptanceTest/package-lock.json @@ -8,7 +8,7 @@ "hasInstallScript": true, "dependencies": { "@umbraco/json-models-builders": "^2.0.29", - "@umbraco/playwright-testhelpers": "^15.0.21", + "@umbraco/playwright-testhelpers": "^15.0.23", "camelize": "^1.0.0", "dotenv": "^16.3.1", "node-fetch": "^2.6.7" @@ -58,20 +58,21 @@ } }, "node_modules/@umbraco/json-models-builders": { - "version": "2.0.29", - "resolved": "https://registry.npmjs.org/@umbraco/json-models-builders/-/json-models-builders-2.0.29.tgz", - "integrity": "sha512-cD20lBDhuLmo2hJk7Ap5hfeDejJhmqjMsANazXgKCulHt5J4HgI3VayXPJx/SyUnCtfc8dylZASOq+2cPzukpA==", + "version": "2.0.30", + "resolved": "https://registry.npmjs.org/@umbraco/json-models-builders/-/json-models-builders-2.0.30.tgz", + "integrity": "sha512-mOXhbvi3mfpkueDaKkMAGKksieB7Pb/pe8e7Hwz3cYoWUQCdGTzlx2ffps6l8LpkRTXZ6IazGg3OwpVFaedDzQ==", + "license": "MIT", "dependencies": { "camelize": "^1.0.1" } }, "node_modules/@umbraco/playwright-testhelpers": { - "version": "15.0.21", - "resolved": "https://registry.npmjs.org/@umbraco/playwright-testhelpers/-/playwright-testhelpers-15.0.21.tgz", - "integrity": "sha512-R5b59dLMJiCB7fEUz3zyKBjF1XetII1FspkpL6Q1INEz0OBzibU9oKKjueMj/HxrhpeszK+8I3OrfZ87mYwuTQ==", + "version": "15.0.23", + "resolved": "https://registry.npmjs.org/@umbraco/playwright-testhelpers/-/playwright-testhelpers-15.0.23.tgz", + "integrity": "sha512-7r7tV45wP47b26lcrv427xINanQ67HTlr89QxprwLgG4otbeDqJO908H9OqsLFoKyk958e1SaGCqBRYbUpJ9EQ==", "license": "MIT", "dependencies": { - "@umbraco/json-models-builders": "2.0.29", + "@umbraco/json-models-builders": "2.0.30", "node-fetch": "^2.6.7" } }, diff --git a/tests/Umbraco.Tests.AcceptanceTest/package.json b/tests/Umbraco.Tests.AcceptanceTest/package.json index 86227ec7c3..48d4b1794e 100644 --- a/tests/Umbraco.Tests.AcceptanceTest/package.json +++ b/tests/Umbraco.Tests.AcceptanceTest/package.json @@ -21,7 +21,7 @@ }, "dependencies": { "@umbraco/json-models-builders": "^2.0.29", - "@umbraco/playwright-testhelpers": "^15.0.21", + "@umbraco/playwright-testhelpers": "^15.0.23", "camelize": "^1.0.0", "dotenv": "^16.3.1", "node-fetch": "^2.6.7" diff --git a/tests/Umbraco.Tests.AcceptanceTest/tests/DefaultConfig/Dictionary/Dictionary.spec.ts b/tests/Umbraco.Tests.AcceptanceTest/tests/DefaultConfig/Dictionary/Dictionary.spec.ts index b18d620f20..28710ac5c1 100644 --- a/tests/Umbraco.Tests.AcceptanceTest/tests/DefaultConfig/Dictionary/Dictionary.spec.ts +++ b/tests/Umbraco.Tests.AcceptanceTest/tests/DefaultConfig/Dictionary/Dictionary.spec.ts @@ -150,10 +150,13 @@ test('can import a dictionary item with descendants', {tag: '@smoke'}, async ({u await umbracoUi.dictionary.clickActionsMenuForDictionary(dictionaryName); await umbracoUi.dictionary.clickImportButton(); await umbracoUi.dictionary.importDictionary(udtFilePath); + // These timeouts are necessary as this test can fail + await umbracoUi.waitForTimeout(500); // Assert // Verify the imported dictionary items display in the list await umbracoUi.reloadPage(); + await umbracoUi.waitForTimeout(500); expect(await umbracoUi.dictionary.doesDictionaryListHaveText(importParentDictionaryName)).toBeTruthy(); expect(await umbracoUi.dictionary.doesDictionaryListHaveText(importChildDictionaryName)).toBeTruthy(); // Verify the imported dictionary items display in the tree