Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/eggys321/jest_practice
Brief jest practice
https://github.com/eggys321/jest_practice
jest tdd
Last synced: 12 days ago
JSON representation
Brief jest practice
- Host: GitHub
- URL: https://github.com/eggys321/jest_practice
- Owner: Eggys321
- Created: 2024-01-16T13:50:31.000Z (about 1 year ago)
- Default Branch: main
- Last Pushed: 2024-01-16T13:55:49.000Z (about 1 year ago)
- Last Synced: 2024-01-16T21:33:32.265Z (about 1 year ago)
- Topics: jest, tdd
- Language: JavaScript
- Homepage:
- Size: 32.2 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
## Programming with JavaScript by meta, this repo is just a brief about jest which was just a part out of this course.
## What is Jest?
Jest is a JavaScript testing framework designed to ensure correctness of any JavaScript codebase. It allows you to write tests with an approachable, familiar and feature-rich API that gives you results quickly. Jest is well-documented, requires little configuration and can be extended to match your requirements.
### How to use
1) Install node, if not installed.. visit follow https://nodejs.org/en .
2) Confirm node installation by typing node --version on any command line.
3) Open a folder and launch on your prefferd text editor(I used Vs code).
4) Run npm init -y on your terminal for your project directory.
5) Then install jest by using this npm i --save-dev jest , this would install jest as a devDependency on your package.json
6) Change the test value in your script tag(package.json file) to "jest", something like this "test": "jest".
7) For further pratice see my addFive.test.js(used for testing my code) and addFive.js## How to run the test command
npm run testfollow this link for jest official page https://jestjs.io/