This project is a "component tests" example using JavaScript and Jest.
- JavaScript
- Jest
- node >= ^16.x - Node installation
- npm >= ^8.x - NPM installation (or yarn)
- Follow-me on GitHub and Linkedin🤣
Install the dependencies:
npm install
Run tests:
npm run test
Wanted Answer:
PASS tests/multiplication.test.js
PASS tests/circleArea.test.js
PASS tests/toCelsius.test.js
PASS tests/textFunction.test.js
PASS tests/circlePerimeter.test.js
Test Suites: 5 passed, 5 total
Tests: 5 passed, 5 total
Snapshots: 0 total
Time: X s, estimated 2 s
Ran all test suites.
It's also possible to watch the Jest tests while it's running:
npm run test:watch
Feel free to complement/report something in pull requests. The project is ours! 🤝