This project provides some simple examples of unit-testing using Mocha Js Framework and Chai Assertion library Prerequisite: Your machine should have node.js and npm installed.
To start the project:
- Pull the following files: package.json, index.js, index.specs.js, and README.md.
- Run 'npm install' command in terminal. File package-lock.json would be generated automatically when you run npm install.
- Run 'npm start' command in terminal, this command will start the server.
To run tests:
- Run 'npm test' command in terminal.
List of files:
- FIle README.md contains the description of the project.
- File package.json contains all necessary settings and dependencies, you don't need to install Mocha and Chai separately.
- File index.js contains functions whick are being tested in this project.
- File index.specs.js contains unit-testing code for that functions.
- File package-lock.json will be generated automatically.