From faa8269228c597af4e14258f128221768779705b Mon Sep 17 00:00:00 2001 From: carlosjr Date: Mon, 18 Oct 2021 11:49:26 +0200 Subject: [PATCH] refactor(e2e): added waitForTimeout on descriptor more menus --- e2e/paths/04-item/08_regularize.spec.js | 1 + e2e/paths/05-ticket/12_descriptor.spec.js | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/e2e/paths/04-item/08_regularize.spec.js b/e2e/paths/04-item/08_regularize.spec.js index d7bab3b7b..a18f81e53 100644 --- a/e2e/paths/04-item/08_regularize.spec.js +++ b/e2e/paths/04-item/08_regularize.spec.js @@ -38,6 +38,7 @@ describe('Item regularize path', () => { }); it('should open the regularize dialog and check the warehouse matches the local user settings', async() => { + await page.waitForTimeout(1000); // initialization of functionality takes about 1000ms to work await page.waitToClick(selectors.itemDescriptor.moreMenu); await page.waitToClick(selectors.itemDescriptor.moreMenuRegularizeButton); const result = await page.waitToGetProperty(selectors.itemDescriptor.regularizeWarehouse, 'value'); diff --git a/e2e/paths/05-ticket/12_descriptor.spec.js b/e2e/paths/05-ticket/12_descriptor.spec.js index dcca61eab..e63d4f431 100644 --- a/e2e/paths/05-ticket/12_descriptor.spec.js +++ b/e2e/paths/05-ticket/12_descriptor.spec.js @@ -41,6 +41,7 @@ describe('Ticket descriptor path', () => { }); it('should delete the ticket using the descriptor menu', async() => { + await page.waitForTimeout(1000); // initialization of functionality takes about 1000ms to work await page.waitToClick(selectors.ticketDescriptor.moreMenu); await page.waitToClick(selectors.ticketDescriptor.moreMenuDeleteTicket); await page.waitToClick(selectors.ticketDescriptor.acceptDialog); @@ -183,7 +184,6 @@ describe('Ticket descriptor path', () => { it('should send the payment SMS using the descriptor menu', async() => { await page.waitForTimeout(2000); // initialization of functionality takes about 1000ms to work await page.waitToClick(selectors.ticketDescriptor.moreMenu); - await page.waitForContentLoaded(); await page.waitToClick(selectors.ticketDescriptor.moreMenuPaymentSMS); await page.waitForSelector(selectors.ticketDescriptor.SMStext); await page.waitPropertyLength(selectors.ticketDescriptor.SMStext, 'value', 128);