intern icon indicating copy to clipboard operation
intern copied to clipboard

[Request] TypeScript integration guide

Open tifrel opened this issue 4 years ago • 0 comments

What's wrong?

A config line line from the official documentation currently breaks tests with TS (source in TS, tests in TS). However I titled this Issue as request for a TypeScript integration guide, because I also encountered issues with certain options in my tsconfig.json, unfortunately I cannot recall the keys right now. At one point not even the debug flag would help and intern just exited non-zero, no message or anything.

Possible solution

Quite often the problem with TS and Intern are related to importing/exporting, maybe the stuff can be fixed there. Also, just better documentation of using Intern with TypeScript would be very much appreciated.

Steps to reproduce (for bugs)

  1. Have running and passing tests
  2. Add "plugins": "node_modules/ts-node/register/index.js", to your intern.json
  3. Get TSError: ⨯ Unable to compile TypeScript:

Environment

Intern version: 4.8.7 Node version: 14.10 NPM version: 6.14.7 TypeScript version: 4.0.2 ts-node version: 9.0.0

tifrel avatar Sep 20 '20 19:09 tifrel