2025-03-05 13:49:06 +00:00
|
|
|
describe('InvoiceInSummary', () => {
|
|
|
|
beforeEach(() => {
|
|
|
|
cy.login('administrative');
|
2025-03-07 10:12:04 +00:00
|
|
|
cy.visit('/#/invoice-in/3/summary');
|
2025-03-05 13:49:06 +00:00
|
|
|
});
|
|
|
|
|
|
|
|
it('should booking and unbooking the invoice properly', () => {
|
|
|
|
const checkbox = '[data-cy="vnLvIs booked"] > .q-checkbox';
|
|
|
|
cy.dataCy('invoiceInSummary_book').click();
|
|
|
|
cy.dataCy('VnConfirm_confirm').click();
|
|
|
|
cy.validateCheckbox(checkbox);
|
|
|
|
});
|
|
|
|
|
|
|
|
it('should open the supplier descriptor popup', () => {
|
|
|
|
cy.intercept('GET', /Suppliers\/\d+/).as('getSupplier');
|
|
|
|
cy.dataCy('invoiceInSummary_supplier').then(($el) => {
|
|
|
|
const description = $el.text().trim();
|
|
|
|
$el.click();
|
|
|
|
cy.wait('@getSupplier').then(() =>
|
|
|
|
cy.validateDescriptor({ description, popup: true }),
|
|
|
|
);
|
|
|
|
});
|
|
|
|
});
|
|
|
|
});
|