Skip to content

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

Notifications You must be signed in to change notification settings

siliconforks/JSCover

 
 

Repository files navigation

JSCover - A JavaScript code coverage measurement tool.

JSCover is an easy-to-use JavaScript code coverage measuring tool. It is based on the popular JSCoverage tool which is no longer maintained. It's big distinguishing factor from other JavaScript coverage tools is that it runs in any browser (supporting JavaScript) allowing coverage measurement of tests that include DOM interaction. It can be run with most tools (e.g. Jasmine, QUnit, etc...).

Development

Before checking-out, [make sure your git client has "Auto CrLf convert" turned off] (https://help.github.com/articles/dealing-with-line-endings). If not, this will cause some tests to fail on Windows machine (the tests may be altered to over-come this if it proves to be a common problem).

Development with JSCover is simple. It is a fairly standard Ant and Java build. Most development has been done with IntelliJ community edition, and some with Eclipse. Project files for both IDEs are checked in, but any editor can be used. Before checking in any changes, be sure to run the build files pre-commit. NB: pre-commit runs the report and enforces coverage limits on unit and integration tests. Acceptance test coverage is collected and can be viewed by running the cobertura-report target manually after pre-commit.

To save repository space, the acceptance test framework HTMLUnit is not checked in. Download HTML Unit (2.10) and unzip it to the same parent directory as JSCover to match the build property html.unit.dir=${basedir}/../htmlunit-2.10. If this property needs changing, the IntelliJ and Eclipse project files will also need altering.

About

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

Resources

Stars

Watchers

Forks

Packages

No packages published