Simple and complete Solid DOM testing utilities that encourage good testing practices.
Inspired completely by preact-testing-library
You want to write tests for your Solid components so that they avoid including implementation details, and are maintainable in the long run.
The Solid Testing Library is a very lightweight solution for testing Solid components. Its primary guiding principle is:
The more your tests resemble the way your software is used, the more confidence they can give you.
This module is distributed via npm which is bundled with node and should be installed
as one of your project's devDependencies
:
npm install --save-dev solid-testing-library
If you using Jest we recommend using solid-jest to properly resolve the browser version of Solid as Jest will default to the server version when run in Node.
💡 You may also be interested in installing @testing-library/jest-dom
so you can use
the custom jest matchers.
TODO