Sign inSign up

simmarn/emma2html

By simmarn

•Updated almost 7 years ago

Create html code coverage report from EclEmma generated xml file

Image
0

246

simmarn/emma2html repository overview

⁠emma2html

Python console app that reads xml file generated by EclEmma (.coveragexml) and creates html report

⁠Dependencies

  • python3
  • xml.etree.ElementTree
  • getopt
  • os
  • sys
  • re
  • shutil
  • glob

⁠Usage

Usage:

python emma2html.py -i <inputfile> -s <coverage settings>

Example:

python emma2html -i vstest.coveragexml -s 90:90:90:90

Coverage settings is made up of threshold settings in percentage class:method:block:line

For example -s 100:90:0:95 means 100& class coverage, 90% method coverage, 0% block coverage and 95% line coverage.

emma2html creates a directory below current directory. The created directory is named CoverageReport and contains the coverage report in html format.

⁠Docker

If using docker linus and windows docker images can be built.

⁠Linux (alpine)

Build

docker build -t simmarn/emma2html:alpine -f docker-alpine/Dockerfile .

Run

docker run -it --rm --name emma2html -v "$PWD":/usr/emma2html -u $(id -u ${USER}):$(id -g ${USER}) simmarn/emma2html:alpine -i vstest.coveragexml -s 80:80:0:80

⁠Windows (nano server)

Build

docker build -t simmarn/emma2html:win -f docker-windows/Dockerfile .

Run using powershell

docker run -it --rm --name emma2html -v ${PWD}:c:\emma2html simmarn/emma2html:win -i vstest.coveragexml -s 80:80:0:80

Tag summary

Content type

Image

Digest

Size

409.1 MB

Last updated

almost 7 years ago

docker pull simmarn/emma2html:win