2022-11-28 08:04:41 +00:00
|
|
|
describe('WorkerList', () => {
|
|
|
|
beforeEach(() => {
|
2022-12-20 10:53:49 +00:00
|
|
|
cy.viewport(1280, 720);
|
|
|
|
cy.login('developer');
|
2022-11-28 08:04:41 +00:00
|
|
|
cy.visit('/#/worker/list');
|
|
|
|
});
|
|
|
|
|
|
|
|
it('should load workers', () => {
|
2023-09-01 11:42:53 +00:00
|
|
|
cy.get('.card-list-body > .list-items > :nth-child(2) > .value > span')
|
2023-08-17 12:48:05 +00:00
|
|
|
.eq(0)
|
2023-09-01 11:42:53 +00:00
|
|
|
.should('have.text', 'victorvd');
|
|
|
|
cy.get('.card-list-body > .list-items > :nth-child(2) > .value > span')
|
2023-08-17 12:48:05 +00:00
|
|
|
.eq(1)
|
2023-09-01 11:42:53 +00:00
|
|
|
.should('have.text', 'JessicaJones');
|
|
|
|
cy.get('.card-list-body > .list-items > :nth-child(2) > .value > span')
|
2023-08-17 12:48:05 +00:00
|
|
|
.eq(2)
|
2023-09-01 11:42:53 +00:00
|
|
|
.should('have.text', 'BruceBanner');
|
2022-11-28 08:04:41 +00:00
|
|
|
});
|
|
|
|
|
|
|
|
it('should open the worker summary', () => {
|
2023-09-01 11:42:53 +00:00
|
|
|
cy.get('.card-list-body .actions .q-btn:nth-child(2)').eq(1).click();
|
2023-08-17 13:36:06 +00:00
|
|
|
cy.get('.summaryHeader div').should('have.text', '1110 - Jessica Jones');
|
|
|
|
cy.get('.summary .header').eq(0).invoke('text').should('include', 'Basic data');
|
|
|
|
cy.get('.summary .header').eq(1).should('have.text', 'User data');
|
2022-11-28 08:04:41 +00:00
|
|
|
});
|
2022-12-20 10:53:49 +00:00
|
|
|
});
|