diff --git a/test/cypress/integration/invoiceIn/invoiceInCorrective.spec.js b/test/cypress/integration/invoiceIn/invoiceInCorrective.spec.js index 2e3098502..7863d6bfa 100644 --- a/test/cypress/integration/invoiceIn/invoiceInCorrective.spec.js +++ b/test/cypress/integration/invoiceIn/invoiceInCorrective.spec.js @@ -10,7 +10,7 @@ describe('InvoiceInCorrective', () => { cy.login('developer'); cy.visit(`/#/invoice-in/1/summary?limit=10`); - cy.get('.header > :nth-child(3) > .q-btn__content > .q-icon').click(); + cy.openActionsDescriptor(); cy.get(createRectificative).click(); cy.get(saveDialog).click(); diff --git a/test/cypress/integration/invoiceIn/invoiceInDescriptor.spec.js b/test/cypress/integration/invoiceIn/invoiceInDescriptor.spec.js index 421d0d20e..a2e9998bb 100644 --- a/test/cypress/integration/invoiceIn/invoiceInDescriptor.spec.js +++ b/test/cypress/integration/invoiceIn/invoiceInDescriptor.spec.js @@ -8,7 +8,7 @@ describe('InvoiceInDescriptor', () => { cy.login('developer'); cy.visit('/#/invoice-in/1/summary'); - cy.get('.header > :nth-child(3) > .q-btn__content > .q-icon').click(); + cy.openActionsDescriptor(); cy.get(firstDescritorOpt).click(); cy.get(dialogBtns).eq(1).click(); cy.get(isBookedField).should('have.attr', 'aria-checked', 'true'); diff --git a/test/cypress/integration/ticket/ticketDescriptor.spec.js b/test/cypress/integration/ticket/ticketDescriptor.spec.js index 7f5dc52bf..fc920f346 100644 --- a/test/cypress/integration/ticket/ticketDescriptor.spec.js +++ b/test/cypress/integration/ticket/ticketDescriptor.spec.js @@ -13,7 +13,7 @@ describe('Ticket descriptor', () => { it('should clone the ticket without warehouse', () => { cy.openLeftMenu(); - cy.get('.header > :nth-child(3) > .q-btn__content > .q-icon').click(); + cy.openActionsDescriptor(); cy.get(toCloneOpt).click(); cy.clickConfirm(); cy.get(warehouseValue).contains('-'); diff --git a/test/cypress/support/commands.js b/test/cypress/support/commands.js index 4ed940ecd..38a23f71c 100755 --- a/test/cypress/support/commands.js +++ b/test/cypress/support/commands.js @@ -239,5 +239,5 @@ Cypress.Commands.add('validateContent', (selector, expectedValue) => { }); Cypress.Commands.add('openActionsDescriptor', () => { - cy.get('.descriptor > .header > .q-btn').click(); + cy.get('.header > :nth-child(3) > .q-btn__content > .q-icon').click(); });