gulp-istanbul-enforcer
Plugin for gulp that enforces coverage thresholds from Istanbul
Last updated 6 years ago by iainjmitchell .
MIT · Repository · Bugs · Original npm · Tarball · package.json
$ cnpm install gulp-istanbul-enforcer 
SYNC missed versions from official npm registry.

gulp-istanbul-enforcer

Build Status

Plugin for gulp that enforces coverage thresholds from Istanbul.

Based on grunt-istanbul-coverage, which enforces istanbul coverage in grunt.

Installation

npm install --save-dev gulp-istanbul-enforcer

Example

Then, add it to your gulpfile.js:

var coverageEnforcer = require("gulp-istanbul-enforcer");

gulp.task('enforce-coverage', function () {
  var options = {
        thresholds : {
          statements : 100,
          branches : 100,
          lines : 100,
          functions : 100
        },
        coverageDirectory : 'coverage',
        rootDirectory : ''
      };
  return gulp
    .src('.')
    .pipe(coverageEnforcer(options));
});

Options

###thresholds Set the required percentage levels for each of the coverage measurements (statements, branches, lines, functions).

###coverageDirectory The directory that istanbul has outputted the coverage results to.

###rootDirectory The root directory of the project, in most cases this can be set to blank.

Current Tags

  • 1.0.3                                ...           latest (6 years ago)

5 Versions

  • 1.0.3                                ...           6 years ago
  • 1.0.2                                ...           7 years ago
  • 1.0.1                                ...           7 years ago
  • 1.0.0                                ...           7 years ago
  • 0.0.1                                ...           7 years ago
Maintainers (1)
Downloads
Today 0
This Week 10
This Month 23
Last Day 3
Last Week 11
Last Month 18
Dependencies (3)
Dev Dependencies (7)

Copyright 2014 - 2016 © taobao.org |