Generate JSCOV reports from mochitest and xpcshell tests locally create the directory where the lcov files will be stored mkdir /tmp/JSCOV generate the lcov files: JS_CODE_COVERAGE_OUTPUT_DIR=/tmp/JSCOV ./mach test PATH/TO/TEST/FILE ... generate chrome-map.json (needed by lcov_rewriter) ./mach build-backend -b ChromeMap rewrite urls in the generated lcov reports (rewrites chrome and resource urls to path to files) ./mach python python/mozbuild/mozbuild/codecoverage/lcov_rewriter.py /tmp/JSCOV/*.info generate HTML report from the rewritten lcov reports (using genhtml binary from the lcov tools) genhtml /tmp/JSCOV/*.info.out -o /tmp/JSCOV-HTML/