lcov

sed/awk: DOS to UNIX path substitution within a file

I have a file that contains this kind of paths: C:\bad\foo.c C:\good\foo.c C:\good\bar\foo.c C:\good\bar\[variable subdir count]\foo.c And I would like to get the following file: C:\bad\foo.c C:/good/foo.c C:/good/bar/foo.c C:/good/bar/[variable subdir count]/foo.c Note that the non matching path should not be modified. I know how...

Is there a way to focus lcov code coverage reports to just one or two directories?

I recently started using lcov to visualize my code coverage. It's a great tool. One thing I'm noticing is that it generates code coverage reports for all the files that I'm using - including those that I'm not interested in. For example, it will give me code coverage reports for boost and mysql++ files. Is there an easy way to force ...

Is there any actively supported lcov port for windows

Hi, I measure coverage for my code using gcov library and I would like to generate coverage report in user-friendly format. I've found lcov utility for that, but it's not compatibile with Windows environment (mainly because of the way the paths are parsed). Does anyone know about actively supported lcov port for Windows? It seems that ...

Viewing LCOV file in Windows

Hi all: Background: I have used JsTestDriverCoverage and generated a test coverage report for my Javascript unit tests. However it is in LCOV format. As a Windows user running on Windows 2003, I can't just read the file since its perl/lunix friendly. Question: are there any ways to either convert the file to a more readable format (u...

Running genhtml using cygwin Perl.exe in Windows

Hi all: I'm trying to run genhtml using perl.exe from Cygwin in Windows. I have installed cygwin and placed genhtml in the bin directory of cygwin. I went to that directory and used the command line in Windows: perl genhtml abc.dat where abc.dat is the name of the lcov file for genhtml. However I got an error saying: Reading data...

Keep getting gcov error when trying to run lcov in Windows command line

Hi all: I was wondering what else is actually needed in order to run lcov in windows command line? Every time when I run perl lcov, I always get a reminder or errors similar to the following: geninfo: ERROR: need tool gcov! I looked into my bin directory, and couldn't find a gcov.exe. I normally do perl genhtml filename to get a ht...

Error on syntax for generating coverage data from multiple files using lcov in Windows

Hi all: I would like some help... I'm having trouble coming up with the syntax to generate coverage data from multiple files using lcov in Windows. I have gcov, lcov and genhtml installed on cygwin (I'm running this under Windows). All of those files are inside cygwin/bin directory. The coverage data I flush through I believe are per...

Unable to merge coverage data using genhtml

Hi all: I'm using genhtml (in Windows under cygwin) to generate a unit test coverage report from 2 coverage data files. They are all coverage data from the same unit test source file. However, when I entered the following command: perl genhtml /home/administrator/coverage1.dat /home/administrator/coverage2.dat I got the following o...

lcov in cross-compile environment

Hello, I have some problems in using gcov/ lcov in a cross-compiler setting. What I have: I took the example main()-Program from the gcov documentation page and successfully compiled, linked and run it. I also was able to run lcov against it to produce the analysis in html pages. All this was in a native i.e. (NON cross-)compiling env...

lcov or gcov -- how to large project analyze

I have large project to analyse. How to use gcov or lcov for it. I found plenty of document for gcov for a single C file. Not much document about lcov too. I'll be thankful for any pointers or tips or links ...

gcov line count is different from no of lines in source code

output of gcov says no of lines executed 70 % of 10 but my code has more than 10 lines.. it does not count braces , else statement please help .. ...

Autotools automatic invocation of lcov after 'make check'

I have successfully set up an autotools project where the tests compiles with instrumentation so I can get a test coverage report. I can get the report by running lcov in the source dir after a successful 'make check'. I now face the problem that I want to automate this step. I would like to add this to 'make check' or to make it a sep...

Excluding certain functions from gcov/lcov coverage results

Is it possible to exclude certain functions or lines of code from the gcov coverage analysis. My code contains certain functions that are used for debugging, and are not exercised as part of my test suite. Such functions reduce the coverage percentage reported by gcov. I would like to exclude these functions from the results. If it is no...

With gcov, is it possible to merge to .gcda files?

I have the same source files (C and Obj-C) being compiled into two targets: the unit test executable and the actual product (which then gets integration tested). The two targets build into different places, so the object files, .gcno and .gcda files are separate. Not all source files are compiled into the unit test, so not all objects wi...

Is it normal for gcov to peg the CPU at 100%

I'm running gcov (through lcov) over a medium-sized project. It's had the CPU at close to 100% for quite a while (not sure exactly how long, but over 30 minutes). The memory isn't ballooning. It seems to be stuck on one task. Is it normal for gcov to do this kind of thing? Edit No luck. Just had to exclude the piece of code that corre...

How to use lcov test coverage tool with Hudson continuous integration?

In my environment developers use lcov from command line when working with source code's module tests. I would like to know if there is a way to easily add reports from lcov to Hudson's builds? I would ease and automate the whole procedure of gathering test source code coverage. ...

How to get Bamboo to handle LCOV formatted code coverage data?

I'm using JsTestDriver for JS unit testing and code coverage (JsTestDriverCodeCoverage) tasks. I've recently started using Atlassian Bamboo for continuous integration, and discovered that it can't handle the LCOV format, which JsTestDriver is generating. Is there a workaround for this problem? Conversion of sorts? ...