diff --git a/cypress/e2e/candidat.cy.js b/cypress/e2e/candidat.cy.js index c1c6aaf79..9b179e21b 100644 --- a/cypress/e2e/candidat.cy.js +++ b/cypress/e2e/candidat.cy.js @@ -79,7 +79,7 @@ describe('Candidat', () => { }); it('should open backoffice public offers', () => { - cy.visit('/backoffice/candidat/offres', { + cy.visit('/backoffice/candidat/offres/public', { onBeforeLoad: function async(window) { window.localStorage.setItem('access-token', '1234'); window.localStorage.setItem('release-version', 'v100'); @@ -115,8 +115,8 @@ describe('Candidat', () => { }); }); - it('should open backoffice public offers and add new opportunity', () => { - cy.visit('/backoffice/candidat/offres', { + it('should open backoffice private offers and add new opportunity', () => { + cy.visit('/backoffice/candidat/offres/private', { onBeforeLoad: function async(window) { window.localStorage.setItem('access-token', '1234'); window.localStorage.setItem('release-version', 'v100'); diff --git a/cypress/e2e/parcours-cv.cy.js b/cypress/e2e/parcours-cv.cy.js index a0f9b7e2e..bb414f641 100644 --- a/cypress/e2e/parcours-cv.cy.js +++ b/cypress/e2e/parcours-cv.cy.js @@ -17,7 +17,7 @@ describe('Parcours CV', () => { fixture: 'opportunity-res', }).as('postOpportunity'); - cy.intercept('POST', '/cv/count').as('postCVCount'); + cy.intercept('POST', '/cv/count', {}).as('postCVCount'); cy.intercept('POST', '/externalMessage', { fixture: 'post-external-message-res', @@ -28,6 +28,9 @@ describe('Parcours CV', () => { }).as('getCandidats'); cy.intercept('GET', '/cv/shares', { total: 184222 }).as('cvShares'); + cy.intercept('GET', '/cv/published', { nbPublishedCVs: 2 }).as( + 'cvPublished' + ); }); it('Ouvrir les filtres et checker Paris', () => { diff --git a/src/components/cv/CVCallToActions/CVCallToActions.tsx b/src/components/cv/CVCallToActions/CVCallToActions.tsx index 70d789516..94d2a23de 100644 --- a/src/components/cv/CVCallToActions/CVCallToActions.tsx +++ b/src/components/cv/CVCallToActions/CVCallToActions.tsx @@ -210,7 +210,7 @@ export const CVCallToActions = ({ } soutenir dans sa recherche d'emploi`} submitText="Envoyer" formSchema={formSendExternalMessage} - onSubmit={async ({ optIn, ...fields }, closeModal) => { + onSubmit={async (fields, closeModal) => { gaEvent(GA_TAGS.PAGE_CV_ENVOYER_CONTACTEZ_MOI_CLIC); fbEvent(FB_TAGS.MESSAGE_SEND); try {