- Test old call back function
- Test Promise resolve
- Test Promise reject
git clone https://github.com/TechMaster/demo-chai.git
cd demo-chai
npm install
npm test
Look into folder test you will see:
- 01_math.js test with thrown error
- 02_user.js tests again db/users.js with promise resolve and reject outcome