twilson63 / express-coffee

A Template for NodeJs Application using Express, CoffeeScript, Jade, Stylus, Nib
http://twilson63.github.io/express-coffee
MIT License
626 stars 152 forks source link

Added parenthesis to done in app_test and replaced .includes with .co… #53

Closed RonakR closed 9 years ago

RonakR commented 9 years ago

…ntainEql as the should.js docs suggest

When I ran the tests on my fresh install of this repo 15 of them failed. The first two were in app_test.coffee where done was missing the parentheses. The others where in posts_test.coffee and users_test.coffee where res.body.should.includes(...) was causing Uncaught TypeError: undefined is not a function for all the failed test. A quick google search lead me to http://stackoverflow.com/questions/29380775/node-mocha-array-should-contain-an-element. After that I did some digging around should.js docs and they said the same so I changed the above to res.body.should.containEql(...) and all the test are passing now.