code-coverage-action icon indicating copy to clipboard operation
code-coverage-action copied to clipboard

Not parsing lcov files generated in ruby?

Open Nealsoni00 opened this issue 2 years ago • 2 comments

Hey! I'm having trouble getting the extension setup: image

When I cat the lcov.info file generated, I get the following format: lcov.info

SF:./app/xxxxxx/xxxxx/xxxxxxxxxx.rb
DA:1,0
DA:2,0
DA:3,0
DA:5,0
DA:6,0
DA:7,0
DA:8,0
DA:9,0
end_of_record
SF:./app/xxxxxx/xxxxx/xxxxxxxxxx.rb
DA:1,0
DA:2,0
...

Nealsoni00 avatar May 10 '22 23:05 Nealsoni00

Hello @Nealsoni00!

Thanks for reaching out. I just checked for the format i was testing with and it looks a bit different:

TN:
SF:src/Router.js
FN:17,(anonymous_0)
FNF:1
FNH:0
FNDA:0,(anonymous_0)
DA:17,0
DA:18,0
LF:2
LH:0
BRF:0
BRH:0
end_of_record

What library do you use to generate Lcov coverage for Ruby?

I think the main problem is with parsing Lcov file itself. We are using this library https://github.com/davglass/lcov-parse#readme to make parsing of Lcov files. Can you try if it works with your generated file?

vitaliimelnychuk avatar May 16 '22 13:05 vitaliimelnychuk

I'm using simplecov-lcov https://github.com/fortissimo1997/simplecov-lcov

It looks like the format is v similar, I'll try that parser later this week!

Nealsoni00 avatar May 17 '22 15:05 Nealsoni00