Skip to content

Commit

Permalink
test fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
ruizajtruss committed Apr 25, 2024
1 parent c386c2e commit dd6e813
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 7 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,8 @@ describe('RateDetailsSchema', () => {
supportingDocuments: [],
ratePreviouslySubmitted: 'YES',
}
]
],
actuaryCommunicationPreference: 'OACT_TO_ACTUARY'
}

const res = await RateDetailsFormSchema({'link-rates': true}).validate(badRateRev, {abortEarly: false})
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -168,6 +168,9 @@ const RateDetailsFormSchema = (activeFeatureFlags?: FeatureFlagSettings) => {
rateForms: Yup.array().of(
SingleRateCertSchema(activeFeatureFlags || {})
),
actuaryCommunicationPreference: Yup.string().required(
'You must select a communication preference'
)
}):
Yup.object().shape({
rateInfos: Yup.array().of(
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -507,16 +507,11 @@ describe('RateDetailsv2', () => {
).toBeInTheDocument()
expect(submitButton).toHaveAttribute('aria-disabled', 'true')
expect(
screen.getByText('There are 2 errors on this page')
screen.getByText('There is 1 error on this page')
).toBeInTheDocument()
expect(
screen.getByText('You must select yes or no')
).toBeInTheDocument()
expect(
screen.getAllByText(
'You must select a communication preference'
)
).toHaveLength(2)
})
})
})
Expand Down

0 comments on commit dd6e813

Please sign in to comment.