diff --git a/site/cypress/integration/mon-entreprise/localisation-field.js b/site/cypress/integration/mon-entreprise/localisation-field.ts similarity index 82% rename from site/cypress/integration/mon-entreprise/localisation-field.js rename to site/cypress/integration/mon-entreprise/localisation-field.ts index 1c5c93548..5839f0caa 100644 --- a/site/cypress/integration/mon-entreprise/localisation-field.js +++ b/site/cypress/integration/mon-entreprise/localisation-field.ts @@ -6,11 +6,18 @@ describe('Champs localisation (simulateur salarié)', function () { } it('should not crash when selecting localisation', function () { + cy.intercept({ + method: 'GET', + hostname: 'geo.api.gouv.fr', + url: '/communes*', + }).as('communes') + cy.visit(encodeURI('/simulateurs/salaire-brut-net')) cy.contains('SMIC').click() cy.contains('button', 'Commune').click() cy.contains('Commune ou code postal').click({ force: true }) cy.focused().type('Steenvoorde') + cy.wait('@communes') cy.contains('Steenvoorde (59114)').click({ force: true }) cy.contains('Suivant').click({ force: true }) cy.contains('Modifier mes réponses').click({ force: true })