forked from java-javascript/client-server-web-apps
-
Notifications
You must be signed in to change notification settings - Fork 0
/
package.json
72 lines (72 loc) · 11.4 KB
/
package.json
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
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
{
"name": "istanbul",
"version": "0.1.22",
"description": "Yet another JS code coverage tool that computes statement, line, function and branch coverage with module loader hooks to transparently add coverage when running tests. Supports all JS coverage use cases including unit tests, server side functional tests and browser tests. Built for scale",
"keywords": [
"coverage",
"code coverage",
"JS code coverage",
"JS coverage"
],
"author": {
"name": "Krishnan Anantheswaran",
"email": "kananthmail-github@yahoo.com"
},
"contributors": [
{
"name": "Reid Burke",
"email": "me@reidburke.com"
},
{
"name": "Martin Cooper",
"email": "mfncooper@gmail.com"
},
{
"name": "Dav Glass",
"email": "davglass@gmail.com"
},
{
"name": "nowamasa",
"email": "nowamasa@gmail.com"
}
],
"preferGlobal": true,
"scripts": {
"pretest": "jshint --config ./node_modules/yui-lint/jshint.json lib/*js lib/command/*js lib/report/*js lib/store/*js lib/util/*js",
"test": "test/run.js",
"posttest": "node ./lib/cli.js check-coverage --statements 95 --branches 80",
"docs": "npm install yuidocjs && node node_modules/yuidocjs/lib/cli.js ."
},
"bin": {
"istanbul": "./lib/cli.js"
},
"dependencies": {
"esprima": "0.9.x",
"escodegen": "0.0.x",
"handlebars": "1.0.x",
"mkdirp": "0.3.x",
"nopt": "2.0.x",
"fileset": "0.1.x",
"which": "1.0.x",
"async": "0.1.x",
"abbrev": "1.0.x",
"wordwrap": "0.0.x"
},
"devDependencies": {
"rimraf": "*",
"nodeunit": "*",
"jshint": "*",
"yui-lint": "*"
},
"TODO": [
"Need a legend for the HTML report + some explanation on how branch coverage is shown",
"figure out a controlled mechanism to suppress branch coverage when impossible-to-test branches are present in source"
],
"readme": "Istanbul - a JS code coverage tool written in JS [![Build Status](https://secure.travis-ci.org/gotwarlost/istanbul.png)](http://travis-ci.org/gotwarlost/istanbul)\n================================================\n\nFeatures\n--------\n\n* All-javascript instrumentation library that tracks **statement, branch,\nand function coverage** and reverse-engineers **line coverage** with 100% fidelity.\n* **Module loader hooks** to instrument code on the fly\n* **Command line tools** to run node unit tests \"with coverage turned on\" and no cooperation\nwhatsoever from the test runner\n* **HTML** and **LCOV** reporting.\n* Ability to use as **middleware** when serving JS files that need to be tested on the browser.\n* Can be used on the **command line** as well as a **library**\n* Based on the awesome `esprima` parser and the equally awesome `escodegen` code generator\n* Well-tested on node 0.4.x, 0.6.x, 0.8.x and the browser (instrumentation library only)\n\nInstalling\n----------\n\n $ npm install -g istanbul\n\nGetting started\n---------------\n\nThe best way to see it in action is to run node unit tests. Say you have a test\nscript `test.js` that runs all tests for your node project without coverage.\n\nSimply:\n\n $ cd /path/to/your/source/root\n $ istanbul cover test.js\n\nand this should produce a `coverage.json`, `lcov.info` and `lcov-report/*html` under `./coverage`\n\nSample of code coverage reports produced by this tool (for this tool!):\n\n* [HTML reports](http://gotwarlost.github.com/istanbul/public/coverage/lcov-report/index.html)\n* [Standard LCOV reports](http://gotwarlost.github.com/istanbul/public/coverage/std-lcov/index.html) (using `genhtml` on the lcov trace file)\n\nUse cases\n---------\n\nSupports the following use cases and more\n\n* transparent coverage of nodejs unit tests\n* ability to use in an <code>npm test</code> script for conditional coverage\n* instrumentation of files in batch mode for browser tests (using yeti for example)\n* Server side code coverage for nodejs by embedding it as custom middleware\n\n\nThe command line\n----------------\n\n $ istanbul help\n\ngives you detailed help on all commands.\n\n Usage: istanbul help <command>\n\n Available commands are:\n\n cover transparently adds coverage information to a node command. Saves\n coverage.json and reports at the end of execution\n\n help shows help\n\n instrument\n instruments a file or a directory tree and writes the\n instrumented code to the desired output location\n\n report writes reports for coverage JSON objects produced in a previous\n run\n\n test cover a node command only when npm_config_coverage is set. Use in\n an `npm test` script for conditional coverage\n\n Command names can be abbreviated as long as the abbreviation is unambiguous\n\nThe `cover` command\n-------------------\n\n $ istanbul cover my-test-script.js -- my test args\n # note the -- between the command name and the arguments to be passed\n\nThe `cover` command can be used to get a coverage object and reports for any arbitrary\nnode script. By default, coverage information is written under `./coverage` - this\ncan be changed using command-line options.\n\nThe `test` command\n-------------------\n\nThe `test` command has almost the same behavior as the `cover` command, except that\nit skips coverage unless the `npm_config_coverage` environment variable is set.\n\nThis helps you set up conditional coverage for tests. In this case you would\nhave a `package.json` that looks as follows.\n\n {\n \"name\": \"my-awesome-lib\",\n \"version\": \"1.0\",\n \"script\": {\n \"test\": \"istanbul test my-test-file.js\"\n }\n }\n\nThen:\n\n $ npm test # will run tests without coverage\n\nAnd:\n\n $ npm test --coverage # will run tests with coverage\n\n**Note**: This needs `node 0.6` or better to work. `npm` for `node 0.4.x` does\nnot support the `--coverage` flag.\n\nThe `instrument` command\n------------------------\n\nInstruments a single JS file or an entire directory tree and produces an output directory tree with instrumented code. This should not be required for running node unit tests but is useful for tests to be run on the browser (using `yeti` for example).\n\nThe `report` command\n-------------------\n\nWrites reports using `coverage*.json` files as the source of coverage information. Reports are available in HTML and LCOV formats. Additional report formats may be plugged in at the library level.\n\nLibrary usage\n-------------\n\nAll the features of istanbul can be accessed as a library using its [public API](http://gotwarlost.github.com/istanbul/public/apidocs/index.html)\n\nChangelog\n---------\n\n* v0.1.22 : Add signature attribute to cobertura method tags to fix NPE by the Hudson publisher\n* v0.1.21 : Add cobertura XML report format; exprimental for now\n* v0.1.20 : Fix HTML/ lcov report interface to be more customizable for middleware needs\n* v0.1.19 : make all hooking non-destructive in that already loaded modules are never reloaded.\nAdd self-test mode so that already loaded istanbul modules can be unloaded prior to hooking.\n* v0.1.18 : Add option to hook in non-destructive mode; i.e. the require cache is not unloaded when hooking\n* v0.1.17 : Export some more objects; undocumented for now\n* v0.1.16 : Fix npm keywords for istanbul which expects an array of strings but was being fed a single string with keywords instead\n* v0.1.15 : Add the 'check-coverage' command so that Istanbul can be used as a posttest script to enforce minimum coverage\n* v0.1.14 : Expose the experimental YUI load hook in the interface\n* v0.1.13 : Internal jshint cleanup, no features or fixes\n* v0.1.12 : Give npm the README that was getting inadvertently excluded\n* v0.1.11 : Merge pull request #14 for HTML tweaks. Thanks @davglass. Add @davglass and @nowamasa as contributors in `package.json`\n* v0.1.10 : Fix to issue #12. Do not install `uncaughtException` handler and pass input error back to CLI using a callback as opposed to throwing.\n* v0.1.9 : Attempt to create reporting directory again just before writing coverage in addition to initial creation\n* v0.1.8 : Fix issue #11.\n* v0.1.7 : Add text summary and detailed reporting available as --print [summary|detail|both|none]. summary is the default if nothing specified.\n* v0.1.6 : Handle backslashes in the file path correctly in emitted code. Fixes #9. Thanks to @nowamasa for bug report and fix\n* v0.1.5 : make object-utils.js work on a browser as-is\n* v0.1.4 : partial fix for issue #4; add titles to missing coverage spans, remove negative margin for missing if/else indicators\n* v0.1.3 : Set the environment variable running_under_istanbul to 1 when that is the case. This allows test runners that use istanbul as a library to back off on using it when set.\n* v0.1.2 : HTML reporting cosmetics. Reports now show syntax-colored JS using `prettify`. Summary tables no longer wrap in awkward places.\n* v0.1.1 : Fixes issue #1. HTML reports use sources embedded inside the file coverage objects if found rather than reading from the filesystem\n* v0.1.0 : Initial version\n\nLicense\n-------\n\nistanbul is licensed under the [BSD License](http://github.com/gotwarlost/istanbul/raw/master/LICENSE).\n\nThird-party libraries\n---------------------\n\nThe following third-party libraries are used by this module:\n\n* abbrev: https://github.com/isaacs/abbrev-js - to handle command abbreviations\n* async: https://github.com/caolan/async - for parallel instrumentation of files\n* escodegen: https://github.com/Constellation/escodegen - for JS code generation\n* esprima: https://github.com/ariya/esprima - for JS parsing\n* fileset: https://github.com/mklabs/node-fileset - for loading and matching path expressions\n* handlebars: https://github.com/wycats/handlebars.js/ - for report template expansion\n* mkdirp: https://github.com/substack/node-mkdirp - to create output directories\n* nodeunit: https://github.com/caolan/nodeunit - dev dependency for unit tests\n* nopt: https://github.com/isaacs/nopt - for option parsing\n* rimraf - https://github.com/isaacs/rimraf - dev dependency for unit tests\n* which: https://github.com/isaacs/node-which - to resolve a node command to a file for the `cover` command\n* wordwrap: https://github.com/substack/node-wordwrap - for prettier help\n* prettify: http://code.google.com/p/google-code-prettify/ - for syntax colored HTML reports. Files checked in under `lib/vendor/`\n\nInspired by\n-----------\n\n* YUI test coverage - https://github.com/yui/yuitest - the grand-daddy of JS coverage tools. Istanbul has been specifically designed to offer an alternative to this library with an easy migration path.\n* cover: https://github.com/itay/node-cover - the inspiration for the `cover` command, modeled after the `run` command in that tool. The coverage methodology used by istanbul is quite different, however\n\nShout out to\n------------\n\n * [mfncooper](https://github.com/mfncooper) - for great brainstorming discussions\n * [reid](https://github.com/reid), [davglass](https://github.com/davglass), the YUI dudes, for interesting conversations, encouragement, support and gentle pressure to get it done :)\n\nWhy the funky name?\n-------------------\n\nSince all the good ones are taken. Comes from the loose association of ideas across coverage, carpet-area coverage, the country that makes good carpets and so on...\n\n\n",
"readmeFilename": "README.md",
"_id": "istanbul@0.1.22",
"dist": {
"shasum": "d20b9c8e5732e0fd7ad7397544c78ad73b88d485"
},
"_from": "istanbul@0.1.22"
}