-
Notifications
You must be signed in to change notification settings - Fork 303
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Amina/test_coverage for icon_message_list in account package #5097
Amina/test_coverage for icon_message_list in account package #5097
Conversation
This pull request is being automatically deployed with Vercel (learn more). 🔍 Inspect: https://vercel.com/deriv/deriv-app/2NoJdeKX3dMPqdz4gHt2b8beJMDe |
A production App ID was automatically generated for this PR. (log)
Click here to copy & paste above information.
|
…ssage-list-spc masteer merge.
it('when the length of message_list is less than 3, it should show messages with icon ', () => { | ||
render(<IconMessageList message_list={['Sample Text1', 'Sample Text2']} />); | ||
expect(screen.getByText(/Sample Text1/i)).toBeInTheDocument(); | ||
expect(screen.getByText(/Sample Text2/i)).toBeInTheDocument(); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
What about check the availability of 'IcCloseCircle' icon also here ? I think it would increase the code coverage.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Done.. Thanks for the suggestion
screen.getByRole('button', { | ||
name: /show more/i, | ||
}) | ||
).toBeInTheDocument(); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
What about checking 'show less' button is not present in the document?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Done.
…ssage-list-spc merging
74f276f
to
bef5522
Compare
Kudos, SonarCloud Quality Gate passed! 0 Bugs No Coverage information |
Changes:
Please include a summary of the change and which issue is fixed below:
When you need to add unit test
When you need to add integration test
Test coverage checklist (for reviewer)
Type of change