0
0
Fork 0

refs #6104 fix tests

This commit is contained in:
Jorge Penadés 2023-12-11 11:59:01 +01:00
parent 42c34f7a46
commit 52622d9a00
3 changed files with 10 additions and 9 deletions

View File

@ -287,9 +287,8 @@ function setDate(type) {
return {
between: [from, to],
};
} else {
return { lte: to };
}
return { lte: to };
}
}
}
@ -657,6 +656,7 @@ setLogTree();
:options="actions"
@update:model-value="selectFilter('action')"
@clear="() => selectFilter('action')"
hide-selected
/>
</QItem>
<QItem class="q-mt-sm">
@ -686,6 +686,7 @@ setLogTree();
option-value="id"
:options="workers"
@update:model-value="selectFilter('userSelect')"
hide-selected
>
<template #option="{ opt, itemProps }">
<QItem

View File

@ -7,7 +7,7 @@ describe('VnLog', () => {
beforeEach(() => {
cy.login('developer');
cy.visit(`/#/claim/${1}/log`);
cy.openRightMenu();
cy.openRightMenu('.timeline');
});
it('should filter by insert actions', () => {

View File

@ -51,15 +51,14 @@ Cypress.Commands.add('getValue', (selector) => {
return cy.get(selector + '.q-checkbox__inner');
}
// Si es un QSelect
else if ($el.find('.q-select__dropdown-icon').length) {
if ($el.find('.q-select__dropdown-icon').length) {
return cy.get(
selector +
'> .q-field > .q-field__inner > .q-field__control > .q-field__control-container > .q-field__native > input'
);
} else {
// Puedes añadir un log o lanzar un error si el elemento no es reconocido
cy.log('Elemento no soportado');
}
// Puedes añadir un log o lanzar un error si el elemento no es reconocido
cy.log('Elemento no soportado');
});
});
@ -136,8 +135,9 @@ Cypress.Commands.add('openListSummary', (row) => {
cy.get('.card-list-body .actions .q-btn:nth-child(2)').eq(row).click();
});
Cypress.Commands.add('openRightMenu', () => {
cy.get('.q-gutter-x-sm > .q-btn > .q-btn__content > .q-icon').click();
Cypress.Commands.add('openRightMenu', (element) => {
if (element) cy.waitForElement(element);
cy.get('#actions-append').click();
});
Cypress.Commands.add('validateContent', (selector, expectedValue) => {