0
0
Fork 0

Merge pull request '#6891 worker tests' (!575) from fixE2e into dev

Reviewed-on: verdnatura/salix-front#575
Reviewed-by: Alex Moreno <alexm@verdnatura.es>
This commit is contained in:
Jorge Penadés 2024-07-29 08:31:51 +00:00
commit 3741999fae
2 changed files with 4 additions and 6 deletions

View File

@ -6,8 +6,6 @@ describe('WorkerList', () => {
});
it('should open the worker summary', () => {
cy.get('.bg-header > :nth-child(2) > .full-width > :nth-child(1) >').type(
'jessica jones{enter}'
);
cy.get('.q-drawer .q-form input[aria-label="Name"]').type('jessica jones{enter}');
});
});

View File

@ -2,7 +2,7 @@ describe('WorkerLocker', () => {
const workerId = 1109;
const lockerCode = '2F';
const input = '.q-card input';
const firstOpt = '[role="listbox"] .q-item:nth-child(1)';
const thirdOpt = '[role="listbox"] .q-item:nth-child(3)';
beforeEach(() => {
cy.viewport(1280, 720);
cy.login('productionBoss');
@ -11,8 +11,8 @@ describe('WorkerLocker', () => {
it('should allocates a locker', () => {
cy.get(input).click();
cy.get(input).type(lockerCode);
cy.get(firstOpt).click();
cy.waitForElement('[role="listbox"]');
cy.get(thirdOpt).click();
cy.saveCard();
cy.get(input).invoke('val').should('eq', lockerCode);
});