Mocha, Chai, & BCrypt

Testing BCrypt on Node.js with Mocha + Chai.

Getting Started

  • Clone this repository.
  • npm install to acquire the modules required for this project.
  • Run mocha. Watch the tests work.

What's going on with this BDD stuff?

  1. Behavior driven development starts off with us placing tests are placed inside of a test/ folder.
  2. Functionality is then then described with a series of tests.
  3. Each test (it) then can expect or describe what a value should be.

Challenge

  1. Read Chai's BDD Docs: http://chaijs.com/api/bdd/
  2. Inspect test/test.js
  3. Modify each test to make them fail.
  4. Correct them to make them pass again!
  5. After inspecting the initial tests inside of the test/test.js folder and getting them to work, uncomment out the starter code at the end of the file and re-test BCrypt by hand.

results matching ""

    No results matching ""