fix: refs #8219 fixed e2e tests
gitea/salix-front/pipeline/pr-dev This commit looks good Details

This commit is contained in:
Jon Elias 2024-11-28 13:00:53 +01:00
parent 65afec0487
commit 454ba4cf7b
5 changed files with 9 additions and 41 deletions

View File

@ -1,9 +1,9 @@
/// <reference types="cypress" />
describe('InvoiceOut manual invoice path', () => {
describe('InvoiceOut list', () => {
const notification = '.q-notification__message';
const invoice = {
Ticket: { val: '8' },
Serial: { val: 'Española rápida', type: 'select' },
Serial: { val: 'Española rapida', type: 'select' },
};
const invoiceError = {
Ticket: { val: '1' },
@ -24,14 +24,7 @@ describe('InvoiceOut manual invoice path', () => {
cy.dataCy('vnSearchBar').find('input').type('{enter}');
cy.dataCy('InvoiceOutFilterAmountBtn').find('input').type('8.88{enter}');
});
it('should download a pdf with one and all invoices', () => {
cy.get(
':nth-child(6) > :nth-child(1) > .q-checkbox > .q-checkbox__inner'
).click();
cy.dataCy('InvoiceOutDownloadPdfBtn').click();
cy.get(
':nth-child(6) > :nth-child(1) > .q-checkbox > .q-checkbox__inner'
).click();
it('should download a pdf', () => {
cy.get('.bg-header > :nth-child(1) > .q-checkbox > .q-checkbox__inner').click();
cy.dataCy('InvoiceOutDownloadPdfBtn').click();
cy.get('.bg-header > :nth-child(1) > .q-checkbox > .q-checkbox__inner').click();

View File

@ -1,5 +1,5 @@
/// <reference types="cypress" />
describe('InvoiceOut manual invoice path', () => {
describe('InvoiceOut manual invoice', () => {
const notification = '.q-notification__message';
beforeEach(() => {
@ -22,6 +22,6 @@ describe('InvoiceOut manual invoice path', () => {
cy.get(notification).should('contains.text', 'Data saved');
cy.get('.q-virtual-scroll__content > :nth-child(1) > :nth-child(3)').click();
cy.get(':nth-child(8) > .value > .link').click();
cy.get('[href="#/invoice-out/6/summary"] > .q-btn > .q-btn__content').click();
cy.get('.header > :nth-child(3) > .q-btn__content').click();
});
});

View File

@ -1,5 +1,5 @@
/// <reference types="cypress" />
describe('InvoiceOut manual invoice path', () => {
describe('InvoiceOut negative bases', () => {
const notification = '.q-notification__message';
beforeEach(() => {

View File

@ -1,5 +1,5 @@
/// <reference types="cypress" />
describe('InvoiceOut manual invoice path', () => {
describe('InvoiceOut summary', () => {
const notification = '.q-notification__message';
const transferInvoice = {
Client: { val: 'employee', type: 'select' },
@ -37,6 +37,7 @@ describe('InvoiceOut manual invoice path', () => {
it('should delete an invoice ', () => {
cy.get('#searchbar input').type('T2222222{enter}');
cy.get('[data-cy="descriptor-more-opts"] > .q-btn__content > .q-icon').click();
cy.get('.q-menu > .q-list > :nth-child(4)').click();
cy.get('[data-cy="VnConfirm_confirm"]').click();
cy.get(notification).should('contains.text', 'InvoiceOut deleted');
@ -48,9 +49,6 @@ describe('InvoiceOut manual invoice path', () => {
cy.get('.q-menu > .q-list > :nth-child(1)').click();
cy.fillInForm(transferInvoice);
cy.get('.q-mt-lg > .q-btn').click();
cy.get(notification).should(
'contains.text',
'The following refund ticket have been created 1000000'
);
cy.get(notification).should('contains.text', 'Transferred invoice');
});
});

View File

@ -1,23 +0,0 @@
/// <reference types="cypress" />
describe('InvoiceOut manual invoice path', () => {
beforeEach(() => {
cy.viewport(1920, 1080);
cy.login('developer');
cy.visit(`/#/invoice-out/global-invoicing`);
});
it('should filter and download as CSV', () => {
cy.get('.q-mb-sm > .q-radio__inner').click();
cy.get('[data-cy="InvoiceOutGlobalClientSelect"]').type('1102');
cy.get('.q-menu .q-item').contains('1102').click();
cy.get('[data-cy="InvoiceOutGlobalSerialSelect"]').click();
cy.get('.q-menu .q-item').contains('global').click();
cy.get('[data-cy="InvoiceOutGlobalCompanySelect"]').type('VNL');
cy.get('.q-menu .q-item').contains('VNL').click();
cy.get('[data-cy="InvoiceOutGlobalPrinterSelect"]').type('printer1');
cy.get('.q-menu .q-item').contains('printer1').click();
cy.get(
'[label="Max date ticket"] > .q-field > .q-field__inner > .q-field__control'
).type('01-01-2000{enter}');
});
});