coverage icon indicating copy to clipboard operation
coverage copied to clipboard

lcov support?

Open Qard opened this issue 11 years ago • 10 comments

It'd be good to have support for lcov.info files. There's a handy lcov parser on npm that you could use.

Qard avatar Oct 07 '14 17:10 Qard

Hi, thanks for your request. Im currently thinking how can i build more parser for the json files, because i am also planning to support https://www.npmjs.org/package/istanbul which is for npm test.

I think after solving https://github.com/philipgiuliani/coverage/issues/3 and finishing the configuration update i will start implementing the "parsers".

philipgiuliani avatar Oct 07 '14 18:10 philipgiuliani

+1 for istanbul. That's what I'm using.

LCOV support gets you support for anything that can output it, which is most things.

All JS coverage tools I'm aware of support LCOV including istanbul, jscoverage and blanket. Most coverage history services, like codecov.io or coveralls.io, also use it.

Qard avatar Oct 07 '14 18:10 Qard

Oh thanks for the information! Wasn't sure what the lcov.info file actually is. I'll start to work on it this or next week!

I also found out that simplecov has an lvoc formatter... https://github.com/fortissimo1997/simplecov-lcov

So i could switch to lcov only for now theoretical. Would be a nice idea.

philipgiuliani avatar Oct 07 '14 19:10 philipgiuliani

I just tested the simplecov-lcov formatter, and it seems that the data is ok. What do you think about changing the table contents to the following:

File Coverage Relevant lines Covered Missed Hits/Line
Filename.ext (progressbar + %) 80 70 10 5.12
Filename2.ext (progressbar + %) 22 16 6 2.54
Filename3.ext (progressbar + %) 34 4 30 0.23

Thats a little bit how coveralls has it.

philipgiuliani avatar Oct 08 '14 07:10 philipgiuliani

I'm down with that.

Qard avatar Oct 09 '14 23:10 Qard

Ok, so you would leave it how it is?

philipgiuliani avatar Oct 10 '14 05:10 philipgiuliani

I just want the filename and percent/progress bar. Everything else is nice to have, but not important to me.

Qard avatar Oct 10 '14 05:10 Qard

Thanks for the feedback!

philipgiuliani avatar Oct 10 '14 06:10 philipgiuliani

+1

listepo avatar Aug 18 '15 11:08 listepo

JFYI there is a lcov-info Atom package which provides similar functionality, but uses a LCOV input file.

Um, maybe you could somehow consolidate the packages as they provide a similar functionality with just small differences here and there...

From users POV it's better to have a single package which can hande both JSON and LCOV files and also easier for developers to contribute fixes/enhancements....

lslezak avatar Dec 10 '15 15:12 lslezak