/// describe('UserPanel', () => { beforeEach(() => { cy.viewport(1280, 720); cy.login('developer'); cy.visit(`/#dashboard`); cy.waitForElement('.q-page', 6000); cy.openUserPanel(); }); it('should notify when update user warehouse', () => { const userWarehouse = '.q-menu .q-gutter-xs > :nth-child(3) > .q-field'; const oldOption = 'VNL'; const newOption = 'VNH'; cy.get(userWarehouse).contains(oldOption); cy.selectOption(userWarehouse, newOption); cy.checkNotification('Data saved'); cy.get(userWarehouse).contains(newOption); // Restore cy.selectOption(userWarehouse, oldOption); }); it('should notify when update user company', () => { const userCompany = '.q-menu .q-gutter-xs > :nth-child(2) > .q-field'; const oldOption = 'Warehouse One'; const newOption = 'TestingWarehouse'; cy.get(userCompany).contains(oldOption); cy.selectOption(userCompany, newOption); cy.checkNotification('Data saved'); cy.get(userCompany).contains(newOption); // Restore cy.selectOption(userCompany, oldOption); }); });