/// function checkRightLabel(index, value, tag = 'Volume: ') { cy.get(`.q-scrollarea__content > :nth-child(${index}) > :nth-child(2) > span`) .should('be.visible') .should('have.text', `${tag}${value}`); } describe('TicketVolume', () => { beforeEach(() => { cy.login('developer'); cy.viewport(1920, 1080); cy.visit('/#/ticket/1/volume'); }); it('Check right panel info', () => { cy.get('.q-page').should('be.visible'); checkRightLabel(2, '0.028'); checkRightLabel(3, '0.014'); checkRightLabel(4, '1.526'); }); it('Descriptors', () => { cy.get(':nth-child(1) > [data-col-field="itemFk"]') .find('span') .should('have.class', 'link') .click(); cy.dataCy('ItemDescriptor').should('exist'); }); });