FFmpeg: FATE lines of code coverage (LCOV)
Posted: Sun Aug 30, 2015 10:56 pm
I'm going to describe the necessary steps to produce an HTML output of code coverage by FFmpeg's FATE tests, just like the one on http://coverage.ffmpeg.org/
It's basically a different version of the article "FATE/TestingCoverage" on FFmpeg wiki.
The OS used is Ubuntu 12.04 (LTS).
Most of these instructions should work for other versions of Ubuntu, as well as Debian too.
Install LCOV package:
Compile/build FFmpeg with GCOV support:
Configure your FFmpeg build as usual, but add the following build option:
In case you've got the fate-suite samples in a non-default location, now would be the right time to add "--samples=path-to-fate-suite/".
Then compile/build FFmpeg:
Run FATE tests:
Even though with these parameters tests run in parallel, his can take a while...
Generate LCOV HTML output:
View HTML page:
Open the file "index.html" in the folder "lcov" in FFmpeg's source tree.
Links:
It's basically a different version of the article "FATE/TestingCoverage" on FFmpeg wiki.
The OS used is Ubuntu 12.04 (LTS).
Most of these instructions should work for other versions of Ubuntu, as well as Debian too.
Install LCOV package:
Code: Select all
$ apt-get install lcov
Configure your FFmpeg build as usual, but add the following build option:
Code: Select all
--toolchain=gcov
Then compile/build FFmpeg:
Code: Select all
$ make clean && make
Code: Select all
# The -j parameter controls thread number for parallel building
$ make -k -j6 fate
Generate LCOV HTML output:
Code: Select all
$ make lcov
Open the file "index.html" in the folder "lcov" in FFmpeg's source tree.
Links: