2024-03-07 14:46:38 +00:00
|
|
|
describe('InvoiceInDescriptor', () => {
|
2024-05-24 07:56:16 +00:00
|
|
|
const dialogBtns = '.q-card__actions button';
|
2024-03-07 14:46:38 +00:00
|
|
|
const firstDescritorOpt = '.q-menu > .q-list > :nth-child(1) > .q-item__section';
|
2024-05-24 07:56:16 +00:00
|
|
|
const isBookedField =
|
|
|
|
'.q-card:nth-child(3) .vn-label-value:nth-child(5) > .value > span';
|
|
|
|
|
2024-03-07 14:46:38 +00:00
|
|
|
it('should booking and unbooking the invoice properly', () => {
|
2024-06-25 14:18:53 +00:00
|
|
|
cy.viewport(1280, 720);
|
2024-03-07 14:46:38 +00:00
|
|
|
cy.login('developer');
|
2024-06-25 14:18:53 +00:00
|
|
|
cy.visit('/#/invoice-in/1/summary');
|
2024-03-07 14:46:38 +00:00
|
|
|
|
|
|
|
cy.openActionsDescriptor();
|
|
|
|
cy.get(firstDescritorOpt).click();
|
2024-05-24 07:56:16 +00:00
|
|
|
cy.get(dialogBtns).eq(1).click();
|
|
|
|
cy.get(isBookedField).should('have.attr', 'title', 'true');
|
2024-03-07 14:46:38 +00:00
|
|
|
|
|
|
|
cy.get(firstDescritorOpt).click();
|
2024-05-24 07:56:16 +00:00
|
|
|
cy.get(dialogBtns).eq(1).click();
|
|
|
|
cy.get(isBookedField).should('have.attr', 'title', 'false');
|
2024-03-07 14:46:38 +00:00
|
|
|
});
|
|
|
|
});
|