0.3.5 • Published 7 years ago

lcov-autosourcemap v0.3.5

Weekly downloads
17
License
MIT
Repository
github
Last release
7 years ago

lcov-sourcemap

Transform an LCOV file using sourcemaps.

This package will look for sourcemap files under the given source directory. The lcov file lists files that are covered. This package will look for sourcemaps with the name <file>.map.


Wat?

  • Run tests against transformed, concat'ed, etc. dist file
  • Get code coverage per source file

Install

Install with npm

npm install --save-dev lcov-autosourcemap

Usage

var lcovSourcemap = require("lcov-sourcemap");
lcovSourcemap("./coverage/lcov-raw.info", "./src").then(function (lcov) {
    // lcov string
});

lcovSourcemap.writeLcov("./coverage/lcov-raw.info", "./src", "./coverage/lcov.info").then(function () {
    // Done!
});

lcovSourcemap(lcovFilePath, sourceDir)

  • lcovFilePath (String): Lcov file.
  • sourceDir (String): Source directory to look for files (checks for existence).
  • return (Promise): Promise containing Lcov string

lcovSourcemap.writeLcov(lcovFilePath, sourcemaps, sourceDir, outputLcovFilePath)

  • Arguments similar to lcovSourceMap
  • outputLcovFilePath (String): Output lcov file path.
  • return (Promise): Resolves when write is complete
0.3.5

7 years ago

0.3.4

7 years ago

0.3.3

8 years ago

0.3.2

8 years ago

0.3.1

8 years ago