Linux v69820.1blu.de 4.15.0 #1 SMP Mon Sep 30 15:36:27 MSK 2024 x86_64
Apache/2.4.58
Server IP : 195.90.215.149 & Your IP : 216.73.217.80
Domains :
Cant Read [ /etc/named.conf ]
User : www-data
Terminal
Auto Root
Create File
Create Folder
Localroot Suggester
Backdoor Destroyer
Readme
/
usr /
share /
nodejs /
istanbul /
lib /
report /
Delete
Unzip
Name
Size
Permission
Date
Action
common
[ DIR ]
drwxr-xr-x
2024-07-09 21:58
templates
[ DIR ]
drwxr-xr-x
2024-07-09 21:58
clover.js
7.58
KB
-rw-r--r--
2023-08-21 05:40
cobertura.js
7.15
KB
-rw-r--r--
2023-08-21 05:40
html.js
21.67
KB
-rw-r--r--
2023-08-21 05:40
index.js
3.29
KB
-rw-r--r--
2023-08-21 05:40
json-summary.js
2.51
KB
-rw-r--r--
2023-08-21 05:40
json.js
2.09
KB
-rw-r--r--
2023-08-21 05:40
lcov.js
2.05
KB
-rw-r--r--
2023-08-21 05:40
lcovonly.js
3.42
KB
-rw-r--r--
2023-08-21 05:40
none.js
895
B
-rw-r--r--
2023-08-21 05:40
teamcity.js
3.01
KB
-rw-r--r--
2023-08-21 05:40
text-lcov.js
1.08
KB
-rw-r--r--
2023-08-21 05:40
text-summary.js
3.23
KB
-rw-r--r--
2023-08-21 05:40
text.js
6.89
KB
-rw-r--r--
2023-08-21 05:40
Save
Rename
/* Copyright (c) 2012, Yahoo! Inc. All rights reserved. Copyrights licensed under the New BSD License. See the accompanying LICENSE file for terms. */ var path = require('path'), objectUtils = require('../object-utils'), Writer = require('../util/file-writer'), util = require('util'), Report = require('./index'); /** * a `Report` implementation that produces a coverage JSON object with summary info only. * * Usage * ----- * * var report = require('istanbul').Report.create('json-summary'); * * * @class JsonSummaryReport * @extends Report * @module report * @constructor * @param {Object} opts optional * @param {String} [opts.dir] the directory in which to write the `coverage-summary.json` file. Defaults to `process.cwd()` */ function JsonSummaryReport(opts) { this.opts = opts || {}; this.opts.dir = this.opts.dir || process.cwd(); this.opts.file = this.opts.file || this.getDefaultConfig().file; this.opts.writer = this.opts.writer || null; } JsonSummaryReport.TYPE = 'json-summary'; util.inherits(JsonSummaryReport, Report); Report.mix(JsonSummaryReport, { synopsis: function () { return 'prints a summary coverage object as JSON to a file'; }, getDefaultConfig: function () { return { file: 'coverage-summary.json' }; }, writeReport: function (collector, sync) { var outputFile = path.resolve(this.opts.dir, this.opts.file), writer = this.opts.writer || new Writer(sync), that = this; var summaries = [], finalSummary; collector.files().forEach(function (file) { summaries.push(objectUtils.summarizeFileCoverage(collector.fileCoverageFor(file))); }); finalSummary = objectUtils.mergeSummaryObjects.apply(null, summaries); writer.on('done', function () { that.emit('done'); }); writer.writeFile(outputFile, function (contentWriter) { contentWriter.println("{"); contentWriter.write('"total":'); contentWriter.write(JSON.stringify(finalSummary)); collector.files().forEach(function (key) { contentWriter.println(","); contentWriter.write(JSON.stringify(key)); contentWriter.write(":"); contentWriter.write(JSON.stringify(objectUtils.summarizeFileCoverage(collector.fileCoverageFor(key)))); }); contentWriter.println("}"); }); writer.done(); } }); module.exports = JsonSummaryReport;