From 6c4268d5fcc483bd1883daa747262e71daf954e7 Mon Sep 17 00:00:00 2001 From: Javier Segarra Date: Fri, 8 Mar 2024 06:40:19 +0100 Subject: [PATCH] refs #7004 fix: test --- e2e/paths/13-supplier/03_fiscal_data.spec.js | 3 ++- .../back/methods/supplier/specs/newSupplier.spec.js | 4 +--- .../back/methods/supplier/specs/updateFiscalData.spec.js | 6 +++--- 3 files changed, 6 insertions(+), 7 deletions(-) diff --git a/e2e/paths/13-supplier/03_fiscal_data.spec.js b/e2e/paths/13-supplier/03_fiscal_data.spec.js index ccd9d7809e..4d0fef778a 100644 --- a/e2e/paths/13-supplier/03_fiscal_data.spec.js +++ b/e2e/paths/13-supplier/03_fiscal_data.spec.js @@ -1,6 +1,6 @@ import getBrowser from '../../helpers/puppeteer'; -describe('Supplier fiscal data path', () => { +fdescribe('Supplier fiscal data path', () => { let browser; let page; @@ -32,6 +32,7 @@ describe('Supplier fiscal data path', () => { }; const errorMessage = await page.sendForm(form, { + city: 'Valencia', taxNumber: 'Wrong tax number' }); const message = await page.sendForm(form, values); diff --git a/modules/supplier/back/methods/supplier/specs/newSupplier.spec.js b/modules/supplier/back/methods/supplier/specs/newSupplier.spec.js index 2b36de5e20..0758d87e29 100644 --- a/modules/supplier/back/methods/supplier/specs/newSupplier.spec.js +++ b/modules/supplier/back/methods/supplier/specs/newSupplier.spec.js @@ -25,9 +25,7 @@ describe('Supplier newSupplier()', () => { try { const options = {transaction: tx}; ctx.args = { - name: 'NEWSUPPLIER', - nif: '12345678Z', - city: 'Gotham' + name: 'NEWSUPPLIER' }; const result = await models.Supplier.newSupplier(ctx, options); diff --git a/modules/supplier/back/methods/supplier/specs/updateFiscalData.spec.js b/modules/supplier/back/methods/supplier/specs/updateFiscalData.spec.js index 7cb95f840a..3f1c811940 100644 --- a/modules/supplier/back/methods/supplier/specs/updateFiscalData.spec.js +++ b/modules/supplier/back/methods/supplier/specs/updateFiscalData.spec.js @@ -61,7 +61,7 @@ describe('Supplier updateFiscalData()', () => { sageTransactionTypeFk, undefined, undefined, - undefined, + city, provinceFk, countryFk, supplierActivityFk, @@ -78,7 +78,7 @@ describe('Supplier updateFiscalData()', () => { const supplier = await models.Supplier.updateFiscalData(ctx, supplierId, undefined, - undefined, + nif, account, phone, undefined, @@ -96,9 +96,9 @@ describe('Supplier updateFiscalData()', () => { options); expect(supplier.account).toEqual(account); + expect(supplier.nif).toEqual(nif); expect(supplier.phone).toEqual(phone); expect(supplier.postCode).toEqual(postCode); - expect(supplier.account).toEqual(account); expect(supplier.city).toEqual(city); expect(supplier.provinceFk).toEqual(provinceFk); });