fix: refs #7957 vn-searchbar test
gitea/salix-front/pipeline/pr-dev This commit looks good Details

This commit is contained in:
Jorge Penadés 2024-12-17 10:44:04 +01:00
parent b1ad357bda
commit efeb32fb28
2 changed files with 3 additions and 7 deletions

View File

@ -159,7 +159,7 @@ async function search() {
:placeholder="t(props.label)"
dense
autofocus
data-cy="vnSearchBar"
data-cy="vn-searchbar"
borderless
>
<template #append>

View File

@ -250,15 +250,11 @@ Cypress.Commands.add('openLeftMenu', (element) => {
Cypress.Commands.add('clearSearchbar', (element) => {
if (element) cy.waitForElement(element);
cy.get(
'#searchbar > form > div:nth-child(1) > label > div:nth-child(1) input'
).clear();
cy.get('[data-cy="vn-searchbar"]').clear();
});
Cypress.Commands.add('writeSearchbar', (value) => {
cy.get('#searchbar > form > div:nth-child(1) > label > div:nth-child(1) input').type(
value
);
cy.get('[data-cy="vn-searchbar"]').type(value);
});
Cypress.Commands.add('validateContent', (selector, expectedValue) => {