How do you install and run Mocha, the Node.js testing module? Getting “mocha: command not found” after install

前端 未结 5 975
暖寄归人
暖寄归人 2020-12-07 11:40

I\'m having trouble getting Mocha to work as expected, and I\'d love to say as documented, but there (appears) to not be much documentation on actually getting the thing run

5条回答
  •  生来不讨喜
    2020-12-07 12:14

    After further reading, and confirmation from Linus G Thiel above, I found I simply had to,

    • Downgrade to Node.js 0.6.12
    • And either,
      • Install Mocha as global
      • Add ./node_modules/.bin to my PATH

提交回复
热议问题