Mainly just trying to get Karma+JSPM to play nice on loading the .ts files but having absolutely no luck.
I see up a discussion repo with a stripped down example.
Basically JSPM within Karma is seemingly ignoring the defaultJSExtensions: true
and package level "defaultExtension": "ts"
configurations when running in Karma giving the following error when attempting to load files:
$ npm test
> [email protected] test C:\examples\karma-jspm-typescript-coverage
> karma start
18 08 2016 17:29:31.937:INFO [karma]: Karma v1.2.0 server started at http://localhost:1337/
18 08 2016 17:29:31.943:INFO [launcher]: Launching browser Chrome with unlimited concurrency
18 08 2016 17:29:31.974:INFO [launcher]: Starting browser Chrome
18 08 2016 17:29:33.075:INFO [Chrome 52.0.2743 (Windows 7 0.0.0)]: Connected on socket /#jTR10wm0CWNIfrdhAAAA with id 75197348
18 08 2016 17:29:33.317:WARN [web-server]: 404: /src/app/app.spec.ts.js
Chrome 52.0.2743 (Windows 7 0.0.0) ERROR
Error: (SystemJS) XHR error (404 Not Found) loading http://localhost:1337/src/app/app.spec.ts.js
Error: XHR error (404 Not Found) loading http://localhost:1337/src/app/app.spec.ts.js
Error loading http://localhost:1337/src/app/app.spec.ts.js
npm ERR! Test failed. See above for more details.
Note the .ts.js extension. Tried everyting from karma-typescript-proprocessor to loading via a different JSPM config than what would be ran with live.
Trying to keep it so there's no need to manage the .js
compiled files and only work with the .ts
files. The development server and bundling/build are fully functional - this testing and coverage piece is my last hurdle.
Please let me know if there any kind of direction you can give me!
proxies : { "/src" : "/base/src", "/jspm_packages" : "/base/src/jspm_packages" },
Changes have been updated in the github project. – Perm