As the title says, when writing incorrect TypeScript-code in a project set up with create-react-app, I don't get any errors in the terminal when running the tests through npm test
. Maybe this is expected behaviour? Would however be nice to get the errors to prevent one from writing incorrect TypeScript in tests as well
Sample of incorrect code:
// App.test.tsx
it('Test of incorrect TypeScript', () => {
let aSimpleString: string = 'hello';
aSimpleString = 5;
});
P.S. In case you were wondering I am using the TypeScript-version of create-react-app through: npx create-react-app my-app --typescript
. Everything else works fine, and if I write incorrect TypeScript in component files the terminal let's me know