⬆️ Upgrade to cypress 6
parent
64c7ce7f88
commit
96b4bf8631
|
@ -5,5 +5,6 @@
|
|||
"language": "fr"
|
||||
},
|
||||
"integrationFolder": "cypress/integration/mon-entreprise",
|
||||
"chromeWebSecurity": false
|
||||
"chromeWebSecurity": false,
|
||||
"retries": 1
|
||||
}
|
||||
|
|
|
@ -0,0 +1 @@
|
|||
{}
|
Binary file not shown.
|
@ -91,7 +91,8 @@ describe('Formulaire demande mobilité', function () {
|
|||
})
|
||||
it('should allow to download PDF', () => {
|
||||
cy.contains(
|
||||
'Je certifie l’exactitude des informations communiquées ci-dessus'
|
||||
'Je certifie l’exactitude des informations communiquées ci-dessus',
|
||||
{ timeout: 10000 }
|
||||
).click()
|
||||
cy.contains('Fait à').click()
|
||||
cy.focused().type('Plougastel')
|
||||
|
|
|
@ -12,6 +12,6 @@ describe('Navigation', function () {
|
|||
it('should go back to home when clicking on logo', () => {
|
||||
cy.visit('/documentation/contrat-salarié')
|
||||
cy.get('img[alt^="logo mon-entreprise"]').click()
|
||||
cy.url().should('be', Cypress.baseUrl)
|
||||
cy.url().should('match', new RegExp(`${Cypress.config().baseUrl}/?`))
|
||||
})
|
||||
})
|
||||
|
|
|
@ -55,7 +55,7 @@ describe('Simulateurs', function () {
|
|||
.invoke('val')
|
||||
.should('match', /1[\s]000/)
|
||||
if (['indépendant', 'dirigeant-sasu'].includes(simulateur)) {
|
||||
cy.get(chargeInputSelector).first().invoke('val').should('be', '500')
|
||||
cy.get(chargeInputSelector).first().invoke('val').should('eq', '500')
|
||||
}
|
||||
cy.contains('€/an').click()
|
||||
})
|
||||
|
@ -71,7 +71,7 @@ describe('Simulateurs', function () {
|
|||
|
||||
it('should allow to go back to the simulation', function () {
|
||||
cy.contains('← ').click()
|
||||
cy.get(inputSelector).first().invoke('val').should('be', '2 000')
|
||||
cy.get(inputSelector).first().invoke('val').should('eq', '2 000')
|
||||
})
|
||||
})
|
||||
)
|
||||
|
@ -117,7 +117,7 @@ describe('Simulateur salarié mode partagé', () => {
|
|||
it('should set input value from URL', function () {
|
||||
cy.visit(urlWithState)
|
||||
cy.wait(800)
|
||||
cy.get(brutInputSelector).first().invoke('val').should('be', '1 539')
|
||||
cy.get(brutInputSelector).first().invoke('val').should('eq', '1 539')
|
||||
|
||||
cy.contains('Voir mes paramètres').click()
|
||||
cy.get('span.answerContent').first().contains('CDD')
|
||||
|
|
|
@ -144,6 +144,12 @@ function FormulairePublicodes() {
|
|||
const isMissingValues = fields.some(
|
||||
({ dottedName }) => !isEmpty(engine.evaluate(dottedName).missingVariables)
|
||||
)
|
||||
|
||||
const missingValues = fields
|
||||
.map(({ dottedName }) => dottedName)
|
||||
.filter(
|
||||
(dottedName) => !isEmpty(engine.evaluate(dottedName).missingVariables)
|
||||
)
|
||||
return (
|
||||
<Animate.fromTop key={clearFieldsKey}>
|
||||
{fields.map(
|
||||
|
@ -203,6 +209,7 @@ function FormulairePublicodes() {
|
|||
<Suspense fallback={null}>
|
||||
<LazyEndBlock fields={fields} isMissingValues={isMissingValues} />
|
||||
</Suspense>
|
||||
{missingValues.join(' / ')}
|
||||
{!!Object.keys(situation).length && (
|
||||
<div
|
||||
css={`
|
||||
|
|
|
@ -105,7 +105,7 @@
|
|||
},
|
||||
"optionalDependencies": {
|
||||
"bundlesize": "^0.18.0",
|
||||
"cypress": "^3.6.1",
|
||||
"cypress": "^6.8.0",
|
||||
"prerender-spa-plugin": "^3.4.0"
|
||||
},
|
||||
"scripts": {
|
||||
|
|
Loading…
Reference in New Issue