feat: refs #8529 enhance InvoiceInVat component with data-cy attribute for isDeductible checkbox
gitea/salix-front/pipeline/pr-dev This commit is unstable
Details
gitea/salix-front/pipeline/pr-dev This commit is unstable
Details
This commit is contained in:
parent
878b311789
commit
816a6197c7
|
@ -237,7 +237,10 @@ function setCursor(ref) {
|
|||
</template>
|
||||
<template #body-cell-isDeductible="{ row }">
|
||||
<QTd align="center">
|
||||
<QCheckbox v-model="row.isDeductible" />
|
||||
<QCheckbox
|
||||
v-model="row.isDeductible"
|
||||
data-cy="isDeductible_checkbox"
|
||||
/>
|
||||
</QTd>
|
||||
</template>
|
||||
<template #body-cell-taxablebase="{ row }">
|
||||
|
|
|
@ -11,13 +11,9 @@ describe('InvoiceInBasicData', () => {
|
|||
});
|
||||
|
||||
it('should edit the provideer and supplier ref', () => {
|
||||
cy.dataCy('UnDeductibleVatSelect').type('4751000000');
|
||||
cy.get('.q-menu .q-item').contains('4751000000').click();
|
||||
cy.get(resetBtn).click();
|
||||
|
||||
cy.waitForElement('#formModel').within(() => {
|
||||
cy.dataCy('vnSupplierSelect').type('Bros nick');
|
||||
})
|
||||
});
|
||||
cy.get('.q-menu .q-item').contains('Bros nick').click();
|
||||
cy.saveCard();
|
||||
cy.get(`${firstFormSelect} input`).invoke('val').should('eq', 'Bros nick');
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
describe('InvoiceInDescriptor', () => {
|
||||
const book = '.summaryHeader > .no-wrap > .q-btn';
|
||||
const firstDescritorOpt = '.q-menu > .q-list > :nth-child(5) > .q-item__section';
|
||||
const checkbox = ':nth-child(5) > .q-checkbox';
|
||||
const firstDescritorOpt = '.q-menu > .q-list > :nth-child(4) > .q-item__section';
|
||||
const checkbox = ':nth-child(4) > .q-checkbox';
|
||||
|
||||
it('should booking and unbooking the invoice properly', () => {
|
||||
cy.viewport(1280, 720);
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
/// <reference types="cypress" />
|
||||
describe('InvoiceInVat', () => {
|
||||
const thirdRow = 'tbody > :nth-child(3)';
|
||||
const firstLineVat = 'tbody > :nth-child(1) > :nth-child(4)';
|
||||
const firstLineVat = 'tbody > :nth-child(1) ';
|
||||
const vats = '[data-cy="vat-sageiva"]';
|
||||
const dialogInputs = '.q-dialog label input';
|
||||
const addBtn = 'tbody tr:nth-child(1) td:nth-child(2) .--add-icon';
|
||||
|
@ -20,6 +20,17 @@ describe('InvoiceInVat', () => {
|
|||
cy.get(vats).eq(0).should('have.value', '8: H.P. IVA 21% CEE');
|
||||
});
|
||||
|
||||
it('should mark the line as deductible VAT', () => {
|
||||
cy.get(`${firstLineVat} [data-cy="isDeductible_checkbox"]`).click();
|
||||
|
||||
cy.saveCard();
|
||||
|
||||
cy.get(`${firstLineVat} [data-cy="isDeductible_checkbox"]`)
|
||||
|
||||
.click();
|
||||
cy.saveCard();
|
||||
});
|
||||
|
||||
it('should add a new row', () => {
|
||||
cy.addRow();
|
||||
cy.fillRow(thirdRow, [true, 2000000001, 30, 'H.P. IVA 10']);
|
||||
|
|
Loading…
Reference in New Issue