-
-
Notifications
You must be signed in to change notification settings - Fork 163
Added unit and e2e tests for the LicenseCode.vue component #130
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
Conversation
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.
I think this is pretty good! You've covered a large majority of the cases I wanted to see, but I think we could add a few more (see my comments). Generally, with tests, you want to test every corner of the thing being tested. I noticed that you tested the richtext "corner", but didn't test the HTML or the print attribution "corners". Testing every possible state permutation isn't necessary, but you generally want to be sure of the basics.
Good work! Just address the comments and I think we should be good to go :)
I also just noticed that there's an uncovered line, please add a test for line 80 to be sure that the empty string there is returned when appropriate :) |
Thank you for reviewing the code even though you were busy...I made all the changes, hence review it whenever you are free :) |
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.
Looks great! Thanks for working on this :)
.assert.elementPresent('.pagination-next') | ||
.click('.pagination-next') | ||
.assert.elementPresent('.select > select') | ||
.click('.select > select') |
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.
This line causes an error running tests:
Error while running .clickElement() protocol action: element click intercepted: Element ... is not clickable at point (871, 102). Other element would receive the click
: ...
If you click on span.select, you will get the result you were expecting, and the tests run fine.
The same happens in LicenseDetailsCard
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.
This test passed when I was sending a pull request, thank you for pointing this out I'll surely edit this :)
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.
This test passed when I was sending a pull request, thank you for pointing this out I'll surely edit this :)
I think it passed for me before, too. Anyways, I opened an issue, and I think it's best if I assign it to you. Thank you for quick reply!
Fixes #117
Description
This
PR
consists of theunit
ande2e
tests for theLicenseCode.vue
componentunit
tests also have thesnapshot
tests.Checklist
Update index.md
).master
branch of the repository.visible errors.
Developer Certificate of Origin