JSCoverage - code coverage for JavaScript

# JSCoverage
code coverage for JavaScript

JSCoverage is a tool that measures code coverage for JavaScript programs.

Code coverage statistics show which lines of a program have been executed (and which have been missed). This information is useful for constructing comprehensive test suites (hence, it is often called test coverage).

JSCoverage works by instrumenting the JavaScript code used in web pages. Code coverage statistics are collected while the instrumented JavaScript code is executed in a web browser.

JSCoverage supports the complete language syntax described in the ECMAScript Language Specification (ECMA-262, 3rd edition). JSCoverage works with any modern standards-compliant web browser - including Internet Explorer (IE 6 and IE 7), Firefox (FF 2 and FF 3), Opera, Safari, and Google Chrome - on Microsoft Windows and GNU/Linux.

JSCoverage is free software, distributed under the GNU General Public License version 2.

## Latest News

### December 11, 2008 - JSCoverage 0.4

JSCoverage 0.4 is available for download.

This release includes many new features:

- The new `jscoverage-server` program is provided as an alternative to the `jscoverage` program. The `jscoverage-server` program is a simple HTTP server which instruments JavaScript code as it is served; this allows you to execute JavaScript and gather code coverage statistics without a preliminary step of creating instrumented code. The `jscoverage-server` program can either serve files directly from the filesystem or run as a proxy server (with the `--proxy` option), instrumenting JavaScript provided by another web server.
- Using `jscoverage-server`, coverage reports can now be stored to the filesystem.
- JSCoverage now recognizes special JavaScript comments which specify that certain lines of code should be ignored in coverage reports.
- The new `--encoding` option provides better support for different character encodings.
- The JSCoverage user interface is now faster and more responsive.
- The new `--no-highlight` option can be used to disable syntax highlighting (giving better performance for large JavaScript files).
- The build system has been modified so that `make install` only installs the `jscoverage` and `jscoverage-server` executables and their manual pages. (Previous versions installed SpiderMonkey library and executable files, which could conflict with other versions of SpiderMonkey installed on your system.)
- JSCoverage now supports several features beyond those found in the ECMAScript Language Specification, including the following:
  - getters and setters
  - `for each` loops
  - generators and iterators
  - the `let` keyword
  - destructuring assignment
  - array comprehensions
  - expression closures
  - generator expressions
  Use the new `--js-version` option to enable these features.

The GCC C++ compiler (`g++`) is now required to compile JSCoverage. (Previously, only the C compiler was needed.)

Please report any bugs you find using the new bug tracker.

### March 31, 2008 - JSCoverage and Firefox 3

The JSCoverage FAQ has been updated to address problems using JSCoverage with Firefox 3.

### March 24, 2008 - JSCoverage in Debian GNU/Linux

JSCoverage is now available in the Debian unstable distribution.

All news items...