From 14e68548817731a8b122e04d82a7b190f29e64f5 Mon Sep 17 00:00:00 2001 From: jorgep Date: Thu, 11 Jan 2024 16:42:41 +0100 Subject: [PATCH] fix: refs #6630 fix invoiceInList test --- test/cypress/integration/invoiceIn/invoiceInList.spec.js | 1 + test/cypress/support/commands.js | 6 +++++- 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/test/cypress/integration/invoiceIn/invoiceInList.spec.js b/test/cypress/integration/invoiceIn/invoiceInList.spec.js index 60d8c5be15..9d3adbc736 100644 --- a/test/cypress/integration/invoiceIn/invoiceInList.spec.js +++ b/test/cypress/integration/invoiceIn/invoiceInList.spec.js @@ -9,6 +9,7 @@ describe('InvoiceInList', () => { beforeEach(() => { cy.login('developer'); cy.visit(`/#/invoice-in`); + cy.clickFilterSearchBtn(); }); it('should redirect on clicking a invoice', () => { diff --git a/test/cypress/support/commands.js b/test/cypress/support/commands.js index 7dc6ffab7c..e4d1cebe18 100755 --- a/test/cypress/support/commands.js +++ b/test/cypress/support/commands.js @@ -178,9 +178,13 @@ Cypress.Commands.add('clearSearchbar', (element) => { }); Cypress.Commands.add('writeSearchbar', (value) => { - cy.get('#searchbar > form > label > div:nth-child(1) input').type(value); + cy.get('#searchbar > form > label > div:nth-child(1) input').type(value); }); Cypress.Commands.add('validateContent', (selector, expectedValue) => { cy.get(selector).should('have.text', expectedValue); }); + +Cypress.Commands.add('clickFilterSearchBtn', () => { + cy.get('.q-item__section > .q-btn > .q-btn__content > .q-icon').click(); +}); // registerCommands();