How to run Mocha tests written in TypeScript?

For anybody who has tried and had problems with typescript-require you may want to try ts-node.

$ npm install -g ts-node
$ mocha --require ts-node/register src/**/*.spec.ts

It also appears that there has been some ongoing discussion about deprecating typescript-require in favor of ts-node.

Leave a Comment

Hata!: SQLSTATE[HY000] [1045] Access denied for user 'divattrend_liink'@'localhost' (using password: YES)