Code coverage report for istanbul/lib/report/none.js

Statements: 100% (9 / 9)      Branches: 100% (0 / 0)      Functions: 100% (3 / 3)      Lines: 100% (9 / 9)      Ignored: none     

All files » istanbul/lib/report/ » none.js
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42          89                                   89 136     89 89   89   2       4       89  
/*
 Copyright (c) 2012, Yahoo! Inc.  All rights reserved.
 Copyrights licensed under the New BSD License. See the accompanying LICENSE file for terms.
 */
 
var util = require('util'),
    Report = require('./index');
 
/**
 * a `Report` implementation that does nothing. Use to specify that no reporting
 * is needed.
 *
 * Usage
 * -----
 *
 *      var report = require('istanbul').Report.create('none');
 *
 *
 * @class NoneReport
 * @extends Report
 * @module report
 * @constructor
 */
function NoneReport() {
    Report.call(this);
}
 
NoneReport.TYPE = 'none';
util.inherits(NoneReport, Report);
 
Report.mix(NoneReport, {
    synopsis: function () {
        return 'Does nothing. Useful to override default behavior and suppress reporting entirely';
    },
    writeReport: function (/* collector, sync */) {
        //noop
        this.emit('done');
    }
});
 
module.exports = NoneReport;