Problem
npm run test runs non-existend tests.
A.k.a: npm run test, npm run compile, npm run rebuild does not remove old no-more-existing test files.
Background
I'm developing an extension for VSCode (in typescript). I set up a couple of automated tests in various files. Later during the process I removed some of the test files. However, npm run test does not seem to be aware of the fact, that tests are deleted - i.e. it still runs them.
After removing the test files files, npm run test will still run the tests contained in these files (probably because their javascript-equivalents are still somewhere in the compiled files area)
Concrete Example Workflow
These are example test files:
test1.test.ts, containstest1test2.test.ts, containstest2test3.test.ts, containstest3
They will (probably) compile to something like
test1.test.jstest2.test.jstest3.test.js
I run npm run test and test1, test2, test3 get executed.
I remove test1.test.ts and test2.test.ts
I run npm run compile and npm run rebuild
I run npm run test and test1, test2, test3 get executed, even though test2 and test3 should be deleted
Question
How can I make npm to remove files, that should not exist anymore?