Using JSCoverage with Selenium

Many people have asked questions about using JSCoverage with a Selenium test suite. There are a number of different approaches to doing this (these will likely be discussed in detail in a future article on this blog). One method is described in “JSCoverage, cobertura and selenium,” on the Mercenary Code blog. This article demonstrates how to access JSCoverage’s coverage data directly from the browser using a Selenium command, as well as how to create a custom report (in Cobertura‘s XML format) from that data.