You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I seem to have this issue that I can't seem to fix. I updated my main tsconfig recently and for some reason my tests now fail.
Full log can be found here : https://pastebin.com/fTHJZ77S ( I deleted majority of the repeating stuff from debug )
Just for anyone else experiencing this, I narrowed down the cause. Unfortunately karma-typescript is deprecated so I don't think it will be fixed but just an FYI for anyone else having this problem.
Basically, there was an undocumented change in TS between TS 5.2.2 and 5.3.3 that removes a property on sourceFile called resolvedModules that karma-typescript uses to find module dependencies and moves it to Program instead. The PR is microsoft/TypeScript#55790 - not mentioned in the changelogs. To fix it, karma-typescript would have to look at Program somehow.
Anyway, not finding any of these modules causes it to say Project has 0 import/require statements, code will not be bundled in the debug logs, and it doesn't bundle the code into a CommonJS IIFE, and it causes it to have references to Node stuff (like "exports" and "require") at the top level which breaks in the browser.
We're probably going to migrate to another test framework but if anyone's stuck with karma-typescript maybe you could fix this with patch-package or a fork. You could also lock TypeScript to 5.2.2 in a pinch.
I seem to have this issue that I can't seem to fix. I updated my main tsconfig recently and for some reason my tests now fail.
Full log can be found here : https://pastebin.com/fTHJZ77S ( I deleted majority of the repeating stuff from debug )
karma versions -
my tsconfig is
My tsconfig.test.json
and finally my karma.conf.js
For whatever reason it doesn't work. I tried #19 and #111, I can't seem to find the issue. Any idea what might be causing it
The text was updated successfully, but these errors were encountered: