Closed daniel-norris closed 3 years ago
Hi! I have raised a PR for this issue. Please feel free to assign this to me. Thanks.
You're assigned @rdhaundiyal-indeed, thanks for contributing. I've left you a comment on the PR.
Hi @daniel-norris - did you get a chance to take a look at the PR? I had updated it with new changes.
Hey @rdhaundiyal-indeed sorry about the delay, I'll take a look this evening and come back to you.
Is your feature request related to a problem? Please describe. Test coverage across the application is low. We need to build confidence that the components have the expected behaviour that we want and to help mitigate any regression in the future.
Describe the solution you'd like We need to implement better test coverage across the library. Ideally each component should be accompanied by a test case written using Jest. At a minimum the test should check whether the component successfully shows any child props. If you are able to include tests for any additional functionality then that would be appreciated!
We should have a test case covering the Toggle component implemented using Jest. More info on Jest can be found here.
For examples of how this is done, take a look at existing test cases in the library. An example would be the CardHeader or Input components.
You can run your tests using
npm run test
or to see test coverage across the librarynpm run test:cov
.This is part of epic #19.