killy971 / codecov-haskell

codecov.io support for haskell code coverage with hpc
http://hackage.haskell.org/package/codecov-haskell
BSD 3-Clause "New" or "Revised" License
29 stars 16 forks source link

Send expression level coverage report #3

Open killy971 opened 9 years ago

killy971 commented 9 years ago

Work branch: https://github.com/guillaume-nargeot/codecov-haskell/tree/expression-level-coverage

Some initial changes were made in a420f6f5ddeb36fade0bb2706b97f007ae512fee and 2c8ca354127912b5b6c622d4a282e065b629e843 to propagate additional information required to compute expression level coverage.

The remaining work consist in performing the following transformations:

Below are examples html outputs produced by hpc, which is what codecov-haskell should try to reproduce. These html reports were generated for the same peace of code, with differing variations of coverage.

No coverage at all: screen shot 2015-01-24 at 10 12 59 am

Coverage when tested with takeUntil (> 1) [] ~=? []: screen shot 2015-01-24 at 10 13 28 am

Coverage when tested with takeUntil (> 1) [2] ~=? [2]: screen shot 2015-01-24 at 10 13 42 am

Coverage when tested with takeUntil (> 1) [1, 2] ~=? [1, 2]: screen shot 2015-01-24 at 10 13 55 am

killy971 commented 9 years ago

Same coverage patterns tested on multi-line if-then-else statements:

screen shot 2015-02-07 at 11 25 01 am

screen shot 2015-02-07 at 11 25 17 am

screen shot 2015-02-07 at 11 25 35 am

screen shot 2015-02-07 at 11 25 51 am