<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml"> <head> <title>Parrot - Make Cover</title> <link rel="stylesheet" type="text/css" href="../../../resources/parrot.css" media="all"> <meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> </head> <body> <div id="wrapper"> <div id="header"> <a href="http://www.parrot.org"> <img border=0 src="../../../resources/parrot_logo.png" id="logo" alt="parrot"> </a> </div> <!-- "header" --> <div id="divider"></div> <div id="mainbody"> <div id="breadcrumb"> <a href="../../../html/index.html">Home</a> » <a href="../../../html/developer.html">Developer Documentation</a> » Make Cover </div> <h1><a name="Make_Cover" >Make Cover</a></h1> <p>docs/dev/coverage.pod - Make Cover Documentation.</p> <h1><a name="Overview" >Overview</a></h1> <p>"make cover" is a very useful tool which generates reports on how well tested parrot code is. The coverage reports are outputted in various formats in cover_db/ after <code>make cover</code> has run. The final result of make cover is a listing of parrot's source files and a matching percentage of how well covered that file is by the tests.</p> <h1><a name="Dependencies" >Dependencies</a></h1> <p>Obviously, the first step would be to get parrot and build it. See <em>docs/intro.pod</em> for more information. To run "make cover" you must first install some Perl tools to aid in the creation of these reports. Make Cover requires the "Devel::Cover" perl module. If you are running Debian/Ubuntu type systems you can run</p> <pre> sudo apt-get install libdevel-cover-perl</pre> <p>or using CPAN:</p> <pre> perl -MCPAN -e 'install Devel::Cover'</pre> <p>and that will install the required module. Other OSes may have this packaged as well, so try to find it. If you do not have a packaged version of this module, head over to <a href="http://search.cpan.org/dist/Devel-Cover/">http://search.cpan.org/dist/Devel-Cover/</a> and install it.</p> <h1><a name="Process" >Process</a></h1> <p>Next, make sure your working parrot directory is as clean as can be. Any left over files can cause problems when generating the coverage reports.</p> <pre> make realclean</pre> <p>or</p> <pre> git clean -dfx</pre> <p>Next, run <code>make test</code> to see if there are any failing tests. Finally you can type in <code>make cover</code> and leave to make a sandwich and something to drink because it's probably going to take a <i>long</i> time to run. If you run into trouble, <code>make fulltest</code> may be of some assistance.</p> <h1><a name="Cover" >Cover</a></h1> <p>If you have run <code>make fullcover</code> before, you know how long it takes to execute that command. Recently a new tool <code>make cover</code> has been added that is much faster, but does not run tests in all runcores.</p> </div> <!-- "mainbody" --> <div id="divider"></div> <div id="footer"> Copyright © 2002-2011, Parrot Foundation. </div> </div> <!-- "wrapper" --> </body> </html>