Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Direction in using new mode in 1.1.0-alpha.2 elsewhere? #12

Open
dgsmith2 opened this issue Jul 1, 2016 · 4 comments
Open

Direction in using new mode in 1.1.0-alpha.2 elsewhere? #12

dgsmith2 opened this issue Jul 1, 2016 · 4 comments
Assignees

Comments

@dgsmith2
Copy link

dgsmith2 commented Jul 1, 2016

Apologies for [a] being completely naive on the topics of calculating and applying coverage as well as [b] potentially asking this in the wrong forum.


I'm working with Typescript, which is being transpiled via webpack using awesome-typescript-loader. Showing coverage on the original *.ts files requires karma-remap-istanbul. However, it seems like it could/should be more native; plus my IDE (IntelliJ) only picks up on the coverage report from karma-coverage for the transpiled code, not the reported coverage from the remap.

I took a stab at updating istanbul-instrumenter-loader to 1.1.0-alpha.2, hoping it would quickly and easily fulfill my dreams: my changes. Sadly, it did not--coverage pertains to the transpiled code.

I'm unsure of where to continue fumbling around. It is to continue in the realm of the webpack loader? The karma-coverage instrumenter config? Both?

Thanks!

@bcoe
Copy link
Contributor

bcoe commented Jan 2, 2017

@dgsmith2 I know this is something that @JaKXz has dealt with in the past there's an issue on nyc related to it:

istanbuljs/nyc#176

There's also a blog post that someone was kind enough to have written:

http://rundef.com/typescript-code-coverage-istanbul-nyc

@JaKXz
Copy link

JaKXz commented Jan 3, 2017

@dgsmith2 at first glance, you could try specifying istanbul-lib-instrument as the instrumenter in the karma config as it says for *.ts(x)? files... and then pass options to it. I just finished moving so I can take a closer look tomorrow - do you have a repo that I can look at? Or a minimal reproduction that matches your current config?

@JaKXz
Copy link

JaKXz commented Jan 6, 2017

@dgsmith2 any luck so far? apologies for the late response, I just noticed that you posted this back in July! 😢

@dgsmith2
Copy link
Author

dgsmith2 commented Jan 6, 2017

@JaKXz I had to move on, but currently trying to make some time to see if I can figure out where I was at the time and how I can potentially update things after reading through the linked resources.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants