Corrige les tests sur master

pull/2108/head
Johan Girod 2022-04-21 17:28:10 +02:00
parent b1cba47f13
commit 3c87d34cab
4 changed files with 7 additions and 6 deletions

View File

@ -14,8 +14,4 @@ describe('Simulateur dividendes', function () {
cy.contains(/[cC]otisations\s+17,2\s*%/)
cy.contains(/[Ii]mpôt\s+12,8\s*%/)
})
it('should allow switching PFU with barème', function () {
cy.get('div [role="radiogroup"] input').eq(0).should('not.be.checked')
})
})

View File

@ -98,7 +98,6 @@ export default function RuleInput<Names extends string = DottedName>({
...props,
}
const meta = getMeta<{ affichage?: string }>(rule.rawNode, {})
if (getVariant(engine.getRule(dottedName))) {
const type =
inputType ??

View File

@ -56,6 +56,7 @@ export default function IndépendantSimulation() {
<>
<RuleInput
inputType="toggle"
missing={false}
dottedName="entreprise . imposition"
onChange={(imposition) => {
dispatch(

View File

@ -31,7 +31,12 @@ export const companySituationSelector = (state: RootState) =>
export const firstStepCompletedSelector = (state: RootState) => {
const situation = situationSelector(state)
return Object.keys(situation).length > 0
return (
Object.keys(situation).filter(
// Hack to prevent questions from showing after selection 'IR or IS' in the toggle above simulator
(dottedName) => dottedName !== 'entreprise . imposition'
).length > 0
)
}
export const targetUnitSelector = (state: RootState) =>