Skip to content

TagSpaces is an offline, open source, document manager with tagging support

fix broken e2e test due to changes in tooltips (#1744)

Stanimir77a97f4581ed
diff --git a/tests/e2e/file.properties.helpers.js b/tests/e2e/file.properties.helpers.js
index a2b1319f3..f4a679d64 100644
--- a/tests/e2e/file.properties.helpers.js
+++ b/tests/e2e/file.properties.helpers.js
@@ -31,7 +31,7 @@ export async function AddRemovePropertiesTags(
// await clickOn('[data-tid=PropertiesTagsSelectTID]');
await global.client.keyboard.press('Enter');
const tagDisplayed = await isDisplayed(
- '[data-tid=PropertiesTagsSelectTID] button[title=' + tagName + ']',
+ '[data-tid=PropertiesTagsSelectTID] button[aria-label=' + tagName + ']',
true,
2000
);
@@ -47,7 +47,7 @@ export async function AddRemovePropertiesTags(
await removeTagFromTagMenu(tagName);
// await global.client.waitForLoadState('networkidle'); //'networkidle'); //'domcontentloaded'); // load
await isDisplayed(
- '[data-tid=PropertiesTagsSelectTID] button[title=' + tagName + ']',
+ '[data-tid=PropertiesTagsSelectTID] button[aria-label=' + tagName + ']',
false,
2000
);
diff --git a/tests/e2e/fileopener.pw.e2e.js b/tests/e2e/fileopener.pw.e2e.js
index 3dc341919..6c9d97199 100644
--- a/tests/e2e/fileopener.pw.e2e.js
+++ b/tests/e2e/fileopener.pw.e2e.js
@@ -211,7 +211,7 @@ describe('TST08 - File folder properties', () => {
it('TST0810 - Tag file drag&drop in file opener [web]', async () => {
const tagName = 'article';
await clickOn('[data-tid=tagLibrary]');
- await dragDrop('button[title=' + tagName + ']', selectorFile);
+ await dragDrop('button[aria-label=' + tagName + ']', selectorFile);
await clickOn(selectorFile);
await clickOn('[data-tid=fileContainerToggleProperties]');
@@ -249,7 +249,7 @@ describe('TST08 - File folder properties', () => {
// await searchEngine('note');
// await waitForNotification();
// await global.client.waitForTimeout(1500); // To do wait for search results
- await expectElementExist(selectorFile, true);
+ await expectElementExist(selectorFile, true, 5000);
// open fileProperties
await clickOn(selectorFile);
diff --git a/tests/e2e/perspective-grid-right-button.pw.e2e.js b/tests/e2e/perspective-grid-right-button.pw.e2e.js
index 69c89947f..0aff61270 100644
--- a/tests/e2e/perspective-grid-right-button.pw.e2e.js
+++ b/tests/e2e/perspective-grid-right-button.pw.e2e.js
@@ -478,7 +478,7 @@ describe('TST50** - Right button on a file', () => {
await createTxtFile();
// await searchEngine('note');
- await expectElementExist(selectorFile, true);
+ await expectElementExist(selectorFile, true, 5000);
// cleanup
// await deleteFirstFile();