Skip to content
This repository has been archived by the owner on Aug 27, 2024. It is now read-only.

Shows how to use mocha and chai to test browser code

License

Notifications You must be signed in to change notification settings

Swaven/mocha-browser-sample

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

3 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

mocha-browser-sample

Shows how to use mocha and chai to test browser code

Dependencies:

mocha, chai, chai-as-promised

if your code uses promises, chai-as-promised is necessary. To include it, you must browserify it as follow:

browserify node_modules/chai-as-promised/chai-as-promised.js --standalone chaiAsPromised -o lib/chai-as-promised.js

Tips & tricks

Using chai's TDD interface, the usual describe and it methods are not available. Instead, you must use suite and test respectively.

About

Shows how to use mocha and chai to test browser code

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages