fix: refs #7323 notification manager
gitea/salix-front/pipeline/pr-dev This commit looks good Details

This commit is contained in:
Carlos Satorres 2025-02-20 09:46:02 +01:00
parent 154b302005
commit 743e07cd64
1 changed files with 8 additions and 3 deletions

View File

@ -2,8 +2,8 @@ describe('WorkerNotificationsManager', () => {
const salesPersonId = 18;
const developerId = 9;
const activeList = '.q-infinite-scroll > :nth-child(1)';
const availableList = '.q-infinite-scroll > :nth-child(2)';
const activeList = ':nth-child(1) > .q-list';
const availableList = ':nth-child(2) > .q-list';
const firstActiveNotification =
':nth-child(1) > .q-list > :nth-child(1) > .q-item > .q-toggle > .q-toggle__inner';
const firstAvailableNotification =
@ -29,6 +29,7 @@ describe('WorkerNotificationsManager', () => {
cy.waitForElement(availableList);
cy.get(activeList)
.children()
.its('length')
.then((beforeSize) => {
cy.get(firstAvailableNotification).click();
@ -45,10 +46,13 @@ describe('WorkerNotificationsManager', () => {
cy.waitForElement(availableList);
cy.get(availableList)
.children()
.its('length')
.then((beforeSize) => {
cy.get(firstActiveNotification).click();
cy.get(availableList).children().should('have.length', beforeSize);
cy.get(availableList)
.children()
.should('have.length', beforeSize + 1);
});
});
@ -58,6 +62,7 @@ describe('WorkerNotificationsManager', () => {
cy.waitForElement(availableList);
cy.get(activeList)
.children()
.its('length')
.then((beforeSize) => {
cy.get(firstAvailableNotification).click();