Note about symbolic linking from "out" to "out_android"
[chromium-blink-merge.git] / docs / code_coverage.md
blob484cecc0e2cda19f85f44aaaf0ded16b273f9db6
1 # Code Coverage
3 ## Categories of coverage
5 *   executed - this line of code was hit during execution
6 *   instrumented - this line of code was part of the compilation unit, but not
7     executed
8 *   missing - in a source file, but not compiled.
9 *   ignored - not an executable line, or a line we don't care about
11 Coverage is calculated as `exe / (inst + miss)`. In general, lines that are in
12 `miss` should be ignored, but our exclusion rules are not good enough.
14 ## Buildbots
16 Buildbots are currently on the
17 [experimental waterfall](http://build.chromium.org/buildbot/waterfall.fyi/waterfall).
18 The coverage figures they calculate come from running some subset of the
19 chromium testing suite.
21 *   [Linux](http://build.chromium.org/buildbot/waterfall.fyi/builders/Linux%20Coverage%20(dbg))
22     - uses `gcov`
23 *   [Windows](http://build.chromium.org/buildbot/waterfall.fyi/builders/Win%20Coverage%20%28dbg%29)
24 *   [Mac](http://build.chromium.org/buildbot/waterfall.fyi/builders/Mac%20Coverage%20%28dbg%29)
26 Also,
28 *   [Coverage dashboard](http://build.chromium.org/buildbot/coverage/)
29 *   [Example coverage summary](http://build.chromium.org/buildbot/coverage/linux-debug/49936/)
30     - the coverage is calculated at directory and file level, and the directory
31     structure is navigable via the **Subdirectories** table.
33 ## Calculating coverage locally
35 TODO
37 ## Advanced Tips
39 Sometimes a line of code should never be reached (e.g., `NOTREACHED()`). These
40 can be marked in the source with `// COV_NF_LINE`. Note that this syntax is
41 exact.