fix: refs #8441 improve field filling and ensure visibility in route extended list tests
gitea/salix-front/pipeline/pr-dev This commit looks good Details

This commit is contained in:
Jose Antonio Tubau 2025-05-19 10:36:29 +02:00
parent e4dfd3d53a
commit 9834c7cf93
1 changed files with 10 additions and 8 deletions

View File

@ -59,8 +59,12 @@ describe('Route extended list', () => {
function fillField(selector, type, value) { function fillField(selector, type, value) {
switch (type) { switch (type) {
case 'select': case 'select':
cy.get(selector).should('be.visible').click().clear().type(value); cy.get(selector)
cy.get('.q-item').contains(value).click(); .should('be.visible')
.click()
.type(`{selectall}{backspace}${value}`);
cy.waitSpinner();
cy.get('.q-menu .q-item').contains(value).click();
break; break;
case 'input': case 'input':
cy.get(selector) cy.get(selector)
@ -82,17 +86,15 @@ describe('Route extended list', () => {
} }
beforeEach(() => { beforeEach(() => {
cy.login('developer');
cy.visit('/#/route/extended-list'); cy.visit('/#/route/extended-list');
cy.reload();
cy.typeSearchbar('{enter}'); cy.typeSearchbar('{enter}');
cy.dataCy(selectors.hideRightMenu).click(); cy.dataCy(selectors.hideRightMenu).click();
}); });
it('Should list routes', () => { before(() => {
cy.get('.q-table') cy.reload();
.children() cy.login('developer');
.should('be.visible')
.should('have.length.greaterThan', 0);
}); });
it('Should create new route', () => { it('Should create new route', () => {