nuzzio / grunt-jscover

Grunt task to parse your source code and generate an instrumented version allowing testing tools to generate code coverage reports

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

grunt-jscover

Grunt task for jscover; which will parse your source code and generate an instrumented version allowing testing tools to generate code coverage reports.

This is a fork of grunt-jscoverage which uses JSCover instead of node-jscoverage.

Installation

Install npm package

npm install grunt-jscover --save-dev

Add this line to your project's Gruntfile.js:

grunt.loadNpmTasks("grunt-jscover");

Usage

note: this task will delete the contents of the output-directory; if one exists; before attempting to parse source.

grunt.initConfig({
  jscover: {
    lib: { 
      src: ['lib'],
      dest: ['lib-cov']
    },
    src: {
      src: ['src'],
      dest: ['src-cov']
    }
  }
});

Run

grunt jscover

About

Grunt task to parse your source code and generate an instrumented version allowing testing tools to generate code coverage reports


Languages

Language:JavaScript 100.0%