From fadf36da69566f5ca86874a1d9e4b54158fb42b6 Mon Sep 17 00:00:00 2001 From: Carlos Jimenez Ruiz Date: Thu, 11 Jun 2020 09:20:44 +0200 Subject: [PATCH] added a css selector to selectors --- e2e/helpers/selectors.js | 3 ++- e2e/paths/05-ticket/14_create_ticket.spec.js | 2 +- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/e2e/helpers/selectors.js b/e2e/helpers/selectors.js index c89be697b..98533b8c3 100644 --- a/e2e/helpers/selectors.js +++ b/e2e/helpers/selectors.js @@ -365,7 +365,8 @@ export default { firstSaleQuantity: 'vn-ticket-summary [name="sales"] vn-table > div > vn-tbody > vn-tr > vn-td:nth-child(3)', firstSaleDiscount: 'vn-ticket-summary [name="sales"] vn-table > div > vn-tbody > vn-tr > vn-td:nth-child(6)', invoiceOutRef: 'vn-ticket-summary > vn-card > vn-horizontal > vn-one:nth-child(1) > vn-label-value:nth-child(7) > section > span', - setOk: 'vn-ticket-summary vn-button[label="SET OK"] > button' + setOk: 'vn-ticket-summary vn-button[label="SET OK"] > button', + descriptorTicketId: 'vn-ticket-descriptor > vn-descriptor-content > div > div.body > div.top > div' }, ticketsIndex: { openAdvancedSearchButton: 'vn-searchbar .append vn-icon[icon="arrow_drop_down"]', diff --git a/e2e/paths/05-ticket/14_create_ticket.spec.js b/e2e/paths/05-ticket/14_create_ticket.spec.js index f377e9e39..26c22ad3d 100644 --- a/e2e/paths/05-ticket/14_create_ticket.spec.js +++ b/e2e/paths/05-ticket/14_create_ticket.spec.js @@ -36,7 +36,7 @@ describe('Ticket create path', () => { it('should check the url is now the summary of the ticket', async() => { await page.waitForState('ticket.card.summary'); - stowawayTicketId = await page.waitToGetProperty('vn-ticket-descriptor > vn-descriptor-content > div > div.body > div.top > div', 'innerText'); + stowawayTicketId = await page.waitToGetProperty(selectors.ticketSummary.descriptorTicketId, 'innerText'); stowawayTicketId = stowawayTicketId.substring(1); });