31 lines
1.3 KiB
JavaScript
31 lines
1.3 KiB
JavaScript
/// <reference types="cypress" />
|
|
|
|
describe('TicketComponents', () => {
|
|
beforeEach(() => {
|
|
cy.login('developer');
|
|
cy.viewport(1920, 1080);
|
|
cy.visit('/#/ticket/1/components');
|
|
});
|
|
it('Should load layout', () => {
|
|
cy.get('.q-page').should('be.visible');
|
|
cy.validateScrollContent([
|
|
{ row: 2, col: 2, text: 'Base to commission: €799.20' },
|
|
{ row: 2, col: 3, text: 'Total without VAT: €807.20' },
|
|
{ row: 3, col: 2, text: 'valor de compra: €425.000' },
|
|
{ row: 3, col: 4, text: 'maná auto: €7.998' },
|
|
{ row: 4, col: 2, text: 'Price: €5.00' },
|
|
{ row: 4, col: 3, text: 'Bonus: €1.00' },
|
|
{ row: 4, col: 5, text: 'Packages: 6' },
|
|
{ row: 4, col: 4, text: 'Zone: Zone pickup A ' },
|
|
{ row: 5, col: 2, text: 'Total price: €16.00' },
|
|
]);
|
|
cy.get(':nth-child(4) > .link').click();
|
|
|
|
cy.dataCy('ZoneDescriptor').should('exist');
|
|
cy.getRowCol('total').should('have.text', '€250.000€247.000€4.970');
|
|
cy.getRowCol('import').should('have.text', '€50.000€49.400€0.994');
|
|
cy.getRowCol('components').should('have.text', 'valor de compramargenmaná auto');
|
|
cy.getRowCol('serie').should('have.text', 'costeempresacartera_comercial');
|
|
});
|
|
});
|