changeset 8:f42b2ac06163

JCov tutorial added Contributed by: alexey.fedorchenko@oracle.com
author ersh
date Wed, 06 Aug 2014 19:05:02 +0400
parents cbeca9e4fbe3
children bfc1e6ee1dfa
files examples/tutorial/Tutorial.html examples/tutorial/doc/document.css examples/tutorial/example1/static_instr.xml examples/tutorial/example2/dynamic_instr.xml examples/tutorial/example3/static_instr_file.xml examples/tutorial/example4/one_command.xml examples/tutorial/example5/jcov_ant_tasks.xml examples/tutorial/example6/jcov_scales.xml examples/tutorial/src/com/oracle/demoapp/Plane.java examples/tutorial/src/com/oracle/demoapp/figures/Disk.java examples/tutorial/src/com/oracle/demoapp/figures/Square.java examples/tutorial/src/com/oracle/demoapp/figures/abstractpack/Figure.java examples/tutorial/test/TestDemoApp1.java examples/tutorial/test/TestDemoApp2.java examples/tutorial/tutorial.build.properties examples/tutorial/tutorial.build.xml
diffstat 16 files changed, 1113 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/examples/tutorial/Tutorial.html	Wed Aug 06 19:05:02 2014 +0400
@@ -0,0 +1,214 @@
+<!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" xml:lang="en" lang="en">
+<head>
+  <title>JCov 2.0 tutorial</title>
+  <link rel="stylesheet" href="doc/document.css" type="text/css">
+  <meta http-equiv="Content-Type"
+ content="text/html; charset=iso-8859-1">
+</head>
+<body>
+<a name="_top"></a>
+<table class="full-width">
+<tbody>
+    <tr>
+      <td class="sun-darkblue">&nbsp;</td>
+    </tr>
+    <tr>
+      <td class="sun-darkblue">
+      <h1>JCov 2.0 Tutorial</h1>     
+      </td>
+    </tr>
+    <tr>
+      <td class="sun-lightblue">&nbsp;</td>
+    </tr>
+  </tbody>
+</table>
+<br>
+<p>
+This tutorial describes
+typical methods of using JCov to get and analyze code coverage
+information for java. It covers the following topics:
+</p>
+
+<p class="nav-link">[<a href="#_top">Top</a>]</p>
+
+<ul>
+  <li> <p class="nav-link"><a href="#_overview">Tutorial Overview</a></p></li>
+  <li> <p class="nav-link"><a href="#_stepping">Stepping Through the Tutorial</a></p></li>
+</ul>
+
+<a name="overview" id="_overview"></a>
+<h2>Tutorial Overview</h2>
+<p class="nav-link">[<a href="#_top">Top</a>]</p>
+<p> The tutorial demonstrate the typical usage of JCov: different ways how you can receive code coverage data using JCov and some JCov features, which could give more useful information about tested code.
+The procedure to receive code coverage information for any product contains 3 general steps:
+<ul>
+  <li>instrumentation of product code (that means adding invocations of code coverage tool methods in all product methods), </li>  
+  <li>running tests using already instrumented product, </li>
+  <li>save and display received CC results.</li> 
+</ul>
+With JCov you can perform these steps separately which is called static instrumentation, and simultaneously which is dynamic instrumentation mode.
+Different approaches of coverage measurement are shown in this tutorial: </p>
+<ul>
+  <li>Static instrumentation with grabber</li>  
+  <li>Dynamic instrumentation with grabber</li>
+  <li>Static instrumentation with file</li> 
+  <li>One command to get coverage</li>
+  <li>JCov ant tasks to get coverage</li>
+  <li>Individual test coverage</li>
+</ul>
+
+<h4>The tutorial contains:</h4>
+<tfoot>
+  <tr> <td colspan="2"><hr class="pTableHr" /> </td></tr>
+ </tfoot>
+<table
+ summary="The tutorial contains:"
+ border="0" cellpadding="12" width="75%">
+  <tbody>
+    <tr valign="top">
+      <th scope="col"><b><u>Component</u></b></th>
+      <th scope="col"><b><u>Description</u></b></th>
+    </tr>
+      <tr valign="top">
+      <td scope="row">tutorial</td>
+      <td>JCov tutorial. Consisting of the following:</td>
+    </tr>
+    </tr>
+    <tr valign="top">
+        <td scope="row"><p><tt>Tutorial.html</tt></p></td>
+        <td><p>Short user guide how to start work with JCov tool.</p></td>
+    </tr>
+    <tr valign="top">
+      <td scope="row"><p><tt>tutorial.build.xml, tutorial.build.properties</tt></p></td>
+      <td><p>The file <code>tutorial.build.xml</code> should be used to build demo application and run tutorial examples. Default properties can be found at <code>tutorial.build.properties file</code>. Without any changes in properties (after building jcov binaries with default values) <code>tutorial.build.xml</code> will create <code>DEMOAPP_BUILD</code> directory with the following structure:
+      	<ul>
+		  <li><code>classes</code> of demo application</li>  
+		  <li><code>example#</code> contains <code>build.xml</code> file to run each example</li>
+		  <li><code>test_classes</code> classes to verify demo application functionality</li> 
+		  <li><code>demoapp.jar</code> demo application jar file</li>		  
+		</ul>
+	</p>
+</td>
+    </tr>
+     <tr valign="top">
+      <td scope="row"><p><tt>/doc</tt></p></td>
+      <td><p>Documentation directory.</p></td>
+    </tr> 
+    <tr valign="top">
+      <td scope="row"><p><tt>/example</tt></p></td>
+      <td><p>There is <code>build.xml</code> in each example directory. During the demo application build these examples will be added to <code>DEMOAPP_BUILD</code> directory.</p></td>
+    </tr>    
+    <tr valign="top">
+      <td scope="row"><p><tt>/src</tt></p></td>
+      <td><p>Source files for simple demo application (the application could count area of figures on the plane).</p></td>
+    </tr>       
+    <tr valign="top">
+      <td scope="row"><p><tt>/test</tt></p></td>
+      <td><p>Source files for tests to verify the demo application functionality.</p></td>
+    </tr>    
+  </tbody>
+</table>
+
+ <tfoot>
+  <tr> <td colspan="2"><hr class="pTableHr" /> </td></tr>
+ </tfoot>
+
+
+<a name="stepping" id="_stepping"></a>
+<h2>Stepping Through the Tutorial</h2>
+<p class="nav-link">[<a href="#_top">Top</a>]</p>
+<p> The tutorial contains basic steps which are discussed in their own section as follows. The each step contains a short description: </p>
+<ul>
+  <li><p class="nav-link"><a href="#_compile">Compile the Source Code</a></p></li>  
+  <li><p class="nav-link"><a href="#_run_example">Run JCov example</a></p></li>
+  <li><p><b>Examples</b>
+  	<ol>
+  		<li><p class="nav-link"><a href="#_static_instr">Static instrumentation with grabber</a></p></li>
+  		<li><p class="nav-link"><a href="#_dynamic_instr">Dynamic instrumentation with grabber</a></p></li>
+		<li><p class="nav-link"><a href="#_static_instr_file">Static instrumentation with file</a></p></li>
+		<li><p class="nav-link"><a href="#_one_command">One command to get coverage</a></p></li>
+  		<li><p class="nav-link"><a href="#_jcov_ant_tasks">JCov ant tasks to get coverage</a></p></li>
+  		<li><p class="nav-link"><a href="#_jcov_scales">Individual test coverage</a></p></li>
+  	</ol>
+  </p></li>  
+</ul>
+
+<a name="compile" id="_compile"></a>
+<h4>Compile the Source Code</h4>
+To compile source code of the example application and tests tutorial contains <code>tutorial.build.xml</code> file in <code>tutorial</code> directory. Execution of the ant command:
+<p><code><b>ant -f tutorial.build.xml</b></code></p>
+ will create <code>DEMOAPP_BUILD</code> directory with all jcov examples for this application. The <code>tutorial.build.properties</code> file contains properties which are used in building demo application and running jcov examples. This simple demo application allows users to create two types of figures (square and disc), add these figures to the plane and count the area of the figures on the plane depending on there color. Tutorial contains two tests in the directory <code>test</code> (<code>TestDemoApp1, TestDemoApp2</code>) for this demo application. All the jcov examples will show how to receive code coverage data for this demo application - how well the demo application is covered by these tests.
+
+<a name="run_example" id="_run_example"></a>
+<h4>Run JCov example</h4>
+After building tutorial demo application (previous step) user can see <code>example#</code> directories in the created <code>DEMOAPP_BUILD</code> directory. Each of these directories contains <code>build.xml</code> file for independent jcov example. Execution of the ant command (in the corresponding <code>example#</code> directory):
+<p><code><b>ant -f build.xml</b></code></p>
+will run jcov example and create in the <code>example#</code> directory <code>coverage</code> directory with the code coverage report for the executed tests.
+
+<a name="static_instr" id="_static_instr"></a>
+<h4>Static instrumentation with grabber</h4>
+This example is using jcov static instrumentation, it means that there are 5 separate steps to receive code coverage information:
+<ol>
+ <li><p>instrumenting the application</p><p><code><b>java -jar jcov.jar instr -t template.xml -o instr_classes $path_to_classes</b></code></p></li>
+ <li><p>starting grabber to receive code coverage results</p><p><code><b>java -jar jcov.jar grabber -t template.xml -o result.xml</b></code></p><p><i>(separate process)</i></p></li>
+ <li><p>running tests</p><p><i>(as usual just adding jcov_network_saver.jar in classpath)</i></p></li>
+ <li><p>saving code coverage results (stopping the grabber)</p><p><code><b>java -jar jcov.jar grabbermanager -kill</b></code></p></li>
+ <li><p>generating report for received code coverage results</p><p><code><b>java -jar jcov.jar repgen -o report result.xml</b></code></p></li>
+</ol>
+All these steps are presented in the <code>static_instr.xml</code> file, the same steps could be executed from the command line.
+The static instrumentation could be more universal, easy to setup for complicated cases (eg. loading large API sets, things that require a large set of Java classes to be loaded), also static instrumentation will give minor overhead on test execution.
+
+<a name="dynamic_instr" id="_dynamic_instr"></a>
+<h4>Dynamic instrumentation with grabber</h4>
+The general procedure to receive code coverage information for any product contains 3 steps: 
+<ol>
+<li>instrument product code</li>
+<li>running tests</li>
+<li>save and display received CC results</li> 
+</ol>
+Step1 and Step2 could be combined together if javaagent is used. In this case application classes will be instrumented on loading, and a <code>template.xml</code> is creating in memory. This example is using jcov dynamic instrumentation:
+
+<ol>
+ <li><p>generate template</p><p><code><b>java -jar jcov.jar tmplgen -t template.xml $path_to_classes</b></code></p><p><i>(this step is needed to include not touched application classes to final code coverage report)</i></p></li>
+ <li><p>starting grabber to receive code coverage results</p><p><code><b>java -jar jcov.jar grabber -t template.xml -o result.xml</b></code></p><p><i>(separate process)</i></p></li>
+ <li><p>running tests</p><p><i>adding javaagent option:</i> <b>"-javaagent:jcov.jar=grabber"</b></p></li>
+ <li><p>saving code coverage results (stopping the grabber)</p><p><code><b>java -jar jcov.jar grabbermanager -kill</b></code></p></li>
+ <li><p>generating report for received code coverage results</p><p><code><b>java -jar jcov.jar repgen -o report result.xml</b></code></p></li>
+</ol>
+All these steps are presented in the <code>dynamic_instr.xml</code> file, the same steps could be executed from the command line. The dynamic instrumentation is good for small and simple cases (eg. small apps, limited API, things that don't require a large set of Java classes to be loaded). Without tmplgen command the report will not include unused classes in dynamic mode.
+
+<a name="static_instr_file" id="_static_instr_file"></a>
+<h4>Static instrumentation with file</h4>
+This example is using jcov static instrumentation without grabber. This approach (or dynamic instrumentation without grabber) could be used for fast results in small and simple cases:
+<ol>
+ <li><p>instrumenting the application</p><p><code><b>java -jar jcov.jar instr -t template.xml -o instr_classes $path_to_classes</b></code></p></li>
+ <li><p>running tests</p><p><i>(adding jcov_file_saver.jar in classpath, setting jcov.template and jcov.file properties)</i></p></li>
+ <li><p>generating report for received code coverage results</p><p><code><b>java -jar jcov.jar repgen -o report result.xml</b></code></p></li>
+</ol>
+All these steps are presented in the <code>static_instr_file.xml</code> file, the same steps could be executed from the command line.
+<a name="one_command" id="_one_command"></a>
+<h4>One command to get coverage</h4>
+This example is using jcov one command feature to get coverage data without understanding any JCov inner processes. To get coverage with JCov one command user needs to specify the application classes and the command to run tests:
+<ol>
+ <li><p>get coverage for tests using one jcov command</p><p><code><b>java -jar jcov.jar jcov -pro $path_to_classes -out report -command "java -cp jcov_network_saver.jar MainTestsExecuter"</b></code></p></li>
+</ol>
+With this approach JCov will perform static instrumentation with grabber in background mode. All these steps are presented in the <code>one_command.xml</code> file, the same steps could be executed from the command line.
+<a name="jcov_ant_tasks" id="_jcov_ant_tasks"></a>
+<h4>JCov ant tasks to get coverage</h4>
+This example shows one of the possibilities to add regular code coverage support to the existing application ant build. JCov ant tasks can be used in application ant build to add static instrumentation with grabber in more convenient way. To be able to use <code>instrument, grabber, grabber-manager, report</code> tasks user needs to add jcov tasks in the application <code>build.xml</code> file:
+<p><code><b>&#60;taskdef name="jcovTasks" classname="com.sun.tdk.jcov.ant.AllTasks" classpath="jcov.jar"/&#62;</b></code></p>
+Usage of the jcov ant tasks is presented in the <code>jcov_ant_tasks.xml</code> file.
+<a name="jcov_scales" id="_jcov_scales"></a>
+<h4>Individual test coverage</h4>
+This example is using jcov static instrumentation with grabber and additional information for each test:
+<ol>
+ <li><p>instrumenting the application</p><p><code><b>java -jar jcov.jar instr -t template.xml -o instr_classes $path_to_classes</b></code></p></li>
+ <li><p>starting grabber to receive code coverage results with tests information</p><p><code><b>java -jar jcov.jar grabber -t template.xml -outtestlist testlist.txt -o result.xml</b></code></p><p><i>(separate process)</i></p></li>
+ <li><p>running tests</p><p><i>(adding jcov_network_saver.jar in classpath, setting jcov.testname property for each test)</i></p></li>
+ <li><p>saving code coverage results (stopping the grabber)</p><p><code><b>java -jar jcov.jar grabbermanager -kill</b></code></p></li>
+ <li><p>generating report for received code coverage results with tests' information</p><p><code><b>java -jar jcov.jar repgen -o report -tests testlist.txt -testsinfo -src $path_to_src result.xml</b></code></p></li>
+</ol>
+All these steps are presented in the <code>jcov_scales.xml</code> file, the same steps could be executed from the command line.
+</body>
+</html>
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/examples/tutorial/doc/document.css	Wed Aug 06 19:05:02 2014 +0400
@@ -0,0 +1,386 @@
+/* CSS FILE FOR UNSTRUCTURED BOOKS FOR UNIX */
+
+/* DEFAULT VALUES */
+body { background-color: #FFFFFF;
+       font-family: Arial, Helvetica, sans-serif;
+       border-top-width: 0px; border-right-width: 0px; 
+       border-bottom-width: 0px; border-left-width: 0px;
+       color: Black; font-size: 12px; font-style: normal;
+       font-variant: normal; font-weight: normal;
+       text-align: left; text-decoration: none;
+       text-indent: 0em; text-transform: none;
+}
+
+
+/* CHAPTER NUMBERING AND TITLES FORMATTING */
+.ChapNumber, .ChapNumberA
+{ font-size: 20px; font-weight: bold; font-style: normal;
+  font-family: arial, helvetica, sans-serif;
+  text-align: left; color: #1E475B; }
+.ChapTitle, .ChapTitleA, .ChapTitleCSR, .ChapTitleC,
+   .ChapTitleG, .ChapTitleI, .ChapTitleP, .ChapTitleS,
+   .PartTitle
+{ font-family: Arial, Verdana, Helvetica, sans-serif;
+  color: #1E475B; font-size: 25px; font-style: normal;
+  font-variant: normal; font-weight: bold;
+  margin-left: 0em; margin-right: 0em; text-align: left;
+  text-decoration: none; text-indent: 0em;
+  text-transform: none;
+}
+.Head1, .Head1A, .Head1CSR, .Head1G, .Head1P
+{ font-family: Arial, Verdana, Helvetica, sans-serif;
+  color: #1E475B; font-size: 20px; font-style: normal;
+  font-variant: normal; font-weight: bold;
+  margin-left: 0em; margin-right: 0em; text-align: left;
+  text-decoration: none; text-indent: 0em;
+  text-transform: none;
+}
+.Head2, .Head2A, .Head2CSR, .Head2G, .Head2P, 
+.Head2-Procedure, .Head2ProcTitle, .Head2-OptFlag
+{ font-family: Arial, Verdana, Helvetica, sans-serif;
+  color: #1E475B; font-size: 18px; font-style: normal;
+  font-variant: normal; text-indent: 0em;
+  font-weight: normal; margin-left: 0em; margin-right: 0em;
+  text-align: left; text-decoration: none; 
+  text-transform: none
+} 
+.Head3, .Head3A, .Head3CSR, .Head3G, .Head3P,
+.Head3-Procedure, .Head3ProcTitle, .Head3-OptCat
+{ font-family: Arial, Verdana, Helvetica, sans-serif;
+  color: #1E475B; font-size: 14px; font-style: normal;
+  font-weight: bold; margin-left: 0em; margin-right: 0em;
+  text-align:left; text-decoration: none; text-indent: 0em;
+  font-variant: normal; text-transform: none
+}
+.Head4 
+{ font-family: Arial, Verdana, Helvetica, sans-serif;
+  color: #1E475B; font-size: 12px; font-style: italic;
+  font-variant: normal; font-weight: bold; margin-left:0em;
+  text-align:left; text-decoration: none; text-indent: 0em;
+  margin-right: 0em; text-transform: none 
+}
+
+
+/* TABLE FORMATTING */
+table { font-family: Arial, Helvetica, sans-serif;
+        background-color: #FFFFFF;
+        margin-top: 0px; padding-top: 0px;
+        border-top-width: 0px; border-right-width: 0px;
+        border-bottom-width: 0px; border-left-width: 0px;
+        margin-bottom: 10px; margin-left: 0px; 
+        padding-bottom: 5px; padding-left: 5px 
+}
+th
+{ font-family: Arial, Helvetica, sans-serif;
+  text-align: left; vertical-align: bottom;
+  padding-top: 5px; padding-right: 10px; 
+  padding-left: 10px; white-space: nowrap
+  border-top-width: 0px; border-right-width: 0px;
+  border-bottom-width: 0px; border-left-width: 0px;
+  padding-bottom: 5px; font-size: 12px;
+}
+td
+{ font-family: Arial, Helvetica, sans-serif;
+  padding-right:10px; padding-left: 10px; padding-top: 7px;
+  padding-bottom: 7px; border-top-width: 0px;
+  border-bottom-width: 0px; border-left-width: 0px;
+  border-right-width: 0px; vertical-align: top;
+  font-size: 12px;
+}
+td p 
+{ font-family: Arial, Helvetica, sans-serif;
+  padding-right:10px; padding-left: 10px; padding-top: 10px
+ border-top-width: 0px; border-right-width: 0px;
+ border-bottom-width: 0px; border-left-width: 0px;
+ vertical-align: top; font-size: 12px;
+}
+td h1 {  text-align: center 
+}
+td h2 {  text-align: center; padding-top: 0px 
+}
+td h3 {  text-align: center; padding-top: 0px
+}
+td h4 {  text-align: center; padding-top: 0px 
+}
+table.Code { margin-bottom: 0.5em; border: 0; 
+ margin-top: 0.5em;
+}
+table.Screen { margin-top: 0.5em; margin-bottom: 0.5em;
+               border: 1px solid  #1E475B; 
+}
+.Untitled { margin-bottom: 1.0em; margin-top: 1.0em;
+}
+.NoBorder { margin-top: 1.0em; margin-bottom: 1.0em;
+  line-height: 2pt; }
+
+
+/* CAPTIONS -- TABLE, CODE, FIGURE */
+caption.TableCaption, caption.TableCaption-Wide,
+caption.TableCaptionA-Wide, caption.TableCaptionG,
+caption.TableCaptionG-Wide, caption.TableCaptionP-Wide,
+caption.TableCaptionP, caption.TableCaptionP-Wide,
+ caption.TableCaptionA
+{ font-family: Arial, Verdana, Helvetica, sans-serif;
+  font-size:12px; font-style: italic; font-variant: normal;
+  font-weight: normal; margin-left: 0em; margin-right: 0em;
+  text-align:left; text-decoration: none; text-indent: 0em;
+  color: Black; text-transform: none
+}
+.TableCaption,.TableCaptionA,.TableCaptionP,.TableCaptionG,
+.TableCaption-Wide,.TableCaptionA-Wide,.TableCaptionP-Wide
+{ margin-top:1.5em; margin-bottom:0.5em; text-align:left; 
+}
+.CodeCaption, .CodeCaption-Wide, .CodeCaptionA,
+.CodeCaptionG, .CodeCaptionG-Wide, .CodeCaptionP,
+.CodeCaptionA-Wide, .CodeCaptionP-Wide
+{ color: Black; font-size: 12px; font-style: italic;
+  font-family: Arial, Verdana, Helvetica, sans-serif;
+  font-variant:normal; font-weight:normal; margin-left:0em;
+  margin-right:0em; text-align:left; text-decoration: none;
+ white-space: pre; text-indent: 0em; text-transform: none
+}
+.FigureBox, .FigureBox-Wide
+{ white-space: pre; font-weight: bold;
+  font-family: arial, helvetica, sans-serif;
+  font-style: normal;
+}
+
+
+/* FONT FORMATTING */
+kbd.UserInput, kbd.UserType 
+{ font-family: courier; font-weight: bold;
+  font-style: normal; white-space: pre; 
+}
+kbd.Filename-Command, kbd.url {
+  font-family: courier;
+  font-weight: normal;
+  white-space: pre;
+  font-style: normal;
+}
+i.Variable 
+{ font-family:Times; font-weight:normal; font-style:italic;
+}
+i.EquationVariables
+ { font-family: Times; font-weight: normal;
+   font-style: italic; 
+}
+i.Title { font-weight: normal; font-style: italic;
+}
+i.Strong { font-style: normal; font-weight: bold; 
+}
+.ErrorTxt { margin-left: 36pt; 
+}
+.ErrorMsg
+{ margin-top:2.5em; white-space: pre; font-family: courier;
+ font-size: 112%; 
+}
+b.TipNote
+{ font-family: helvetica, sans-serif; font-style: normal;
+  font-weight: bold; font-size: 115%; 
+}
+pre.ScreenText
+{ font-family:courier; white-space:pre; line-height: 16px; 
+}
+pre.Codeline 
+{ font-family:courier; white-space:pre; margin-left:35px; 
+ line-height: 16px;
+}
+
+
+/* STEPS */
+.Step1, .Step1-, .StepSingle 
+{ font-family: Arial, Verdana, Helvetica, sans-serif;
+  font-size:12px; font-style: normal; font-variant: normal;
+  font-weight: bold; margin-left: 0em; margin-right: 0em;
+  text-align:left; text-decoration: none; text-indent: 0em;
+  color: Black; text-transform: none; margin-left: 22px; 
+}
+.Step2, .Step2- 
+{ font-family: Arial, Verdana, Helvetica, sans-serif;
+  font-size:12px; font-style: normal; font-variant: normal;
+  font-weight: bold; margin-left: 0em; margin-right: 0em;
+  text-align:left; text-decoration: none; text-indent: 0em;
+  color: Black; text-transform: none; margin-left: 65px; 
+}
+.Step3 .Step3- 
+{ font-family: Arial, Verdana, Helvetica, sans-serif;
+  color: Black; font-size: 12px; font-style: normal;
+  font-variant: normal; font-weight: bold;
+  margin-left: 0em; margin-right: 0em; text-align: left; 
+  text-decoration: none; text-indent: 0em;
+  text-transform: none; margin-left: 115px;
+}
+/* MARGINS FOR PARAGRAPHS ASSOCIATED WITH STEPS */
+.StepPara1 { margin-left: 38px; font-weight: normal; }
+.StepPara2 { margin-left: 80px; font-weight: normal; } 
+.StepPara3 { margin-left: 125px; font-weight: normal; }
+
+
+/* LISTS */
+.List1, .List1-
+{ font-family: Arial, Verdana, Helvetica, sans-serif;
+  font-size:12px; font-style: normal; font-variant: normal;
+  font-weight:normal; margin-left: 22px; margin-right: 0em;
+  text-align:left; text-decoration: none; text-indent: 0em;
+  color: Black; text-transform: none;
+}
+.List2, .List2- 
+{ font-family: Arial, Verdana, Helvetica, sans-serif;
+  font-size:12px; font-style: normal; font-variant: normal;
+  font-weight:normal; margin-left: 65px; margin-right: 0em;
+  text-align:left; text-decoration: none; text-indent: 0em;
+  color: Black; text-transform: none; 
+}
+.List3 
+{ font-family: Arial, Verdana, Helvetica, sans-serif;
+  font-size:12px; font-style: normal; font-variant: normal;
+  font-weight:normal; margin-left:115px; margin-right: 0em;
+  text-align:left; text-decoration: none; text-indent: 0em;
+  color: Black; text-transform: none;
+}
+.List3-
+{ font-family: Arial, Verdana, Helvetica, sans-serif;
+  font-size:12px; font-style: normal; font-variant: normal;
+  font-weight:normal; margin-left:112px; margin-right: 0em;
+  text-align:left; text-decoration:none; text-indent: 0em;
+  color: Black; text-transform: none;
+}
+.ParaIndent1 { margin-left: 39px; }
+.ParaIndent2 { margin-left: 80px; }
+.ParaIndent3 { margin-left: 127px; }
+
+
+/* TOC FORMATS */
+.PartTitleTOC 
+{ margin: 1.25em 0em 0em 2em; font-size: 16px;
+  font-weight: bold; font-style: normal;
+  font-family: arial, helvetica, sans-serif; 
+}
+.ChapTitleTOC, .ChapTitleATOC, .ChapTitleCTOC,
+ .ChapTitleCSRTOC, .ChapTitleGTOC, .ChapTitleITOC,
+ .ChapTitlePTOC, .ChapTitleSTOC
+{ margin-left: 2.5em; margin-right: 0em;
+  font-style: normal; font-size: 15px; font-weight: normal;
+  font-family: arial, helvetica, sans-serif; 
+} 
+.Head1TOC, .Head1ATOC, .Head1PTOC, .Head1CSRTOC, .Head1GTOC
+{ font-family: Arial, Verdana, Helvetica, sans-serif;
+  font-size:15px; font-style: normal; font-variant: normal;
+  font-weight: normal; margin-left: 5em; margin-right: 0em;
+  text-align:left; text-decoration: none; text-indent: 0em;
+  color: Black; text-transform: none; 
+}
+.Head2TOC,.Head2ATOC,.Head2-ProcedureTOC,.Head2-OptCatTOC,
+.Head2-OptFlagTOC, .Head2CRSTOC, .Head2PTOC
+{ margin-left: 7.5em; margin-right: 0em; font-size: 14px;
+  font-weight: normal; font-style: normal;
+  font-family: arial, helvetica, sans-serif; 
+}
+.Head3TOC, .Head3ATOC, .Head3-ProcedureTOC, .Head3CSRTOC,
+.Head3-OptCatTOC, .Head3PTOC
+{ margin-left: 10em; margin-right: 0em; 
+  font-size: 13px; font-weight: normal; font-style: normal;
+  font-family: arial, helvetica, sans-serif;
+}
+    
+
+/* LOT, LOF, LOC formats */
+.FigureCaptionLOF, .FigureCaption-WideLOF,
+.FigureCaptionALOF, .FigureCaptionPLOF,
+.FigureCaptionGLOF, .FigureCaptionG-WideLOF,
+.FigureCaptionA-WideLOF, .FigureCaptionP-WideLOF
+{ margin: .65em 0em 0em 2em; font-weight: normal;
+  font-family: arial, helvetica, sans-serif; 
+  color: Black; font-size: 15px; font-variant: normal;
+  text-align:left; text-decoration: none; text-indent: 0em;
+  font-style: normal; text-transform: none;
+}
+  
+.TableCaptionLOT, .TableCaption-WideLOT, .TableCaptionALOT,
+.TableCaptionA-WideLOT, .TableCaptionGLOT,
+.TableCaptionPLOT, .TableCaptionP-WideLOT,
+.TableCaptionG-WideLOT
+{ margin: .65em 0em 0em 2em; font-weight: normal;
+  font-family: arial, helvetica, sans-serif; 
+  color: Black; font-size: 15px; font-variant: normal;
+  text-align:left; text-decoration: none; text-indent: 0em;
+  font-style: normal; text-transform: none;
+}
+  
+.CodeCaptionLOP, .CodeCaption-WideLOP, .CodeCaptionALOP,
+.CodeCaptionA-WideLOP, .CodeCaptionG-WideLOP,
+.CodeCaptionGLOP, .CodeCaptionP,.CodeCaptionP-WideLOP
+{ margin: .65em 0em 0em 2em; font-weight: normal;
+  font-family: arial, helvetica, sans-serif; 
+  color: Black; font-size: 15px; font-variant: normal;
+  text-align:left; text-decoration: none; text-indent: 0em;
+  font-style: normal; text-transform: none;
+}
+
+
+/* OTHER STUFF -- MOSTLY CMSG */
+.sun-darkblue { font-family: Arial, Helvetica, sans-serif ;
+                color: #FFFFFF; background-color: #1E475B
+}
+.sun-lightblue { background-color: #638093
+}
+.sun-verylightblue {  background-color: #91AEA8
+}
+.go-right {  text-align: right }
+.go-left {  text-align: left }
+.copyright 
+{ font-family:Arial, Helvetica, sans-serif; font-size:10px}
+.fine-print
+{ font-family:Arial, Helvetica, sans-serif; font-size:10px}
+.full-width {  width: 100% }
+/* Definitions for horizontal rules */
+.pTableHr { color: #1E475B; background-color: #1E475B }
+.pHr { color: #1E475B; background-color: #1E475B }
+
+
+/* INDEX FORMATS */
+.GroupTitlesIX 
+{ font-family: Arial, Verdana, Helvetica, sans-serif;
+  font-size:18px; font-style: normal; font-variant: normal;
+  margin: 1.5em 0em 0em 0em; text-align: left;
+  text-decoration: none; text-transform: none;
+  text-indent: 0em; font-weight: bold; color: #1E475B; 
+}
+p.Level1IX
+{ font-family: Arial, Verdana, Helvetica, sans-serif;
+  font-style: normal; font-variant: normal;
+  font-weight: normal; margin: .25em 0em 0em 2em;
+  text-align:left; text-decoration: none; text-indent: 0em;
+  font-size: 13px; color: Black; text-transform: none;
+}
+p.Level2IX 
+{ font-family: Arial, Verdana, Helvetica, sans-serif;
+  font-size:13px; font-style: normal; font-variant: normal;
+  font-weight: normal; margin: .25em 0em 0em 4em;
+  text-decoration: none; text-transform: none;
+  text-indent: 0em; text-align: left; color: Black; 
+}
+p.Level3IX {
+{ font-family: Arial, Verdana, Helvetica, sans-serif;
+  font-size:13px; font-style: normal; font-variant: normal;
+  font-weight: normal; margin: .25em 0em 0em 6em;
+  text-decoration: none; text-transform: none;
+  text-indent: 0em; text-align: left; color: Black; 
+}
+p.Level4IX 
+{ font-family: Arial, Verdana, Helvetica, sans-serif;
+  font-size: 13px; font-style: normal; font-variant: normal;
+  font-weight: normal; margin: .25em 0em 0em 8em;
+  text-decoration: none; text-transform: none;
+  text-indent: 0em; text-align: left; color: Black; 
+}
+
+
+/* GLOSSARY TERM FORMATS*/
+.GlossTerm 
+{ font-size: 115%; font-weight: bold; font-style: normal; }
+.GlossText { margin: 0em 0em 3.0em 3.0em; }
+.footnote { vertical-align: super; font-size: 10px; }
+span.Footnote { font-size: small; vertical-align: super }
+.Linebreak { line-height: 0.5em; }
+
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/examples/tutorial/example1/static_instr.xml	Wed Aug 06 19:05:02 2014 +0400
@@ -0,0 +1,63 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<project name="JCov_static_instr" default="build" basedir=".">
+
+    <property file="../../tutorial.build.properties"/>
+
+    <target name="build">
+
+        <!--instrument classes-->
+        <java classname="com.sun.tdk.jcov.Instr" fork="true" failonerror="true">
+            <classpath>
+                <pathelement location="${jcov.jar}"/>
+            </classpath>
+            <arg line="-template template.xml -output instr_classes ../../${tutorial.result.dir}/classes/"/>
+        </java>
+
+        <parallel>
+            <!--start grabber-->
+            <java classname="com.sun.tdk.jcov.Grabber" fork="true" failonerror="true">
+                <classpath>
+                    <pathelement location="${jcov.jar}"/>
+                </classpath>
+                <arg line="-template template.xml -o result.xml"/>
+            </java>
+
+        <sequential>
+            <!--running tests-->
+            <java classname="TestDemoApp1" fork="true" failonerror="true">
+                <classpath>
+                    <pathelement location="${jcov.network.saver.jar}"/>
+                    <pathelement location="../../${tutorial.result.dir}/test_classes"/>
+                    <pathelement location="instr_classes"/>
+                </classpath>
+            </java>
+
+            <java classname="TestDemoApp2" fork="true" failonerror="true">
+                <classpath>
+                    <pathelement location="${jcov.network.saver.jar}"/>
+                    <pathelement location="../../${tutorial.result.dir}/test_classes"/>
+                    <pathelement location="instr_classes"/>
+                </classpath>
+            </java>
+
+            <!--stop grabber-->
+            <java classname="com.sun.tdk.jcov.GrabberManager" fork="true">
+                <classpath>
+                    <pathelement location="${jcov.jar}"/>
+                </classpath>
+                <arg line="-kill"/>
+            </java>
+
+            <!--generate report-->
+            <java classname="com.sun.tdk.jcov.RepGen" fork="true" failonerror="true">
+                <classpath>
+                    <pathelement location="${jcov.jar}"/>
+                </classpath>
+                <arg line="-output coverage/report result.xml"/>
+            </java>
+        </sequential>
+        </parallel>
+
+    </target>
+
+</project>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/examples/tutorial/example2/dynamic_instr.xml	Wed Aug 06 19:05:02 2014 +0400
@@ -0,0 +1,63 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<project name="JCov_dynamic_instr" default="build" basedir=".">
+
+    <property file="../../tutorial.build.properties"/>
+
+    <target name="build">
+
+        <!--generate template-->
+        <java classname="com.sun.tdk.jcov.TmplGen" fork="true" failonerror="true">
+            <classpath>
+                <pathelement location="${jcov.jar}"/>
+            </classpath>
+            <arg line="-template template.xml ../../${tutorial.result.dir}/classes/"/>
+        </java>
+
+        <parallel>
+            <!--start grabber-->
+            <java classname="com.sun.tdk.jcov.Grabber" fork="true" failonerror="true">
+                <classpath>
+                    <pathelement location="${jcov.jar}"/>
+                </classpath>
+                <arg line="-template template.xml -o result.xml"/>
+            </java>
+
+            <sequential>
+                <!--running tests with dynamic instrumantation-->
+                <java classname="TestDemoApp1" fork="true" failonerror="true">
+                    <classpath>
+                        <pathelement location="../../${tutorial.result.dir}/classes"/>
+                        <pathelement location="../../${tutorial.result.dir}/test_classes"/>
+                    </classpath>
+                    <jvmarg value="-javaagent:${jcov.jar}=grabber"/>
+                </java>
+
+                <java classname="TestDemoApp2" fork="true" failonerror="true">
+                    <classpath>
+                        <pathelement location="../../${tutorial.result.dir}/classes"/>
+                        <pathelement location="../../${tutorial.result.dir}/test_classes"/>
+                    </classpath>
+                    <jvmarg value="-javaagent:${jcov.jar}=grabber"/>
+                </java>
+
+                <!--stop grabber-->
+                <java classname="com.sun.tdk.jcov.GrabberManager" fork="true">
+                    <classpath>
+                        <pathelement location="${jcov.jar}"/>
+                    </classpath>
+                    <arg line="-kill"/>
+                </java>
+
+                <!--generate report-->
+                <java classname="com.sun.tdk.jcov.RepGen" fork="true" failonerror="true">
+                    <classpath>
+                        <pathelement location="${jcov.jar}"/>
+                    </classpath>
+                    <arg line="-output coverage/report result.xml"/>
+                </java>
+            </sequential>
+        </parallel>
+
+    </target>
+
+</project>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/examples/tutorial/example3/static_instr_file.xml	Wed Aug 06 19:05:02 2014 +0400
@@ -0,0 +1,47 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<project name="JCov_static_instr_file" default="build" basedir=".">
+
+    <property file="../../tutorial.build.properties"/>
+
+    <target name="build">
+
+        <!--instrument classes-->
+        <java classname="com.sun.tdk.jcov.Instr" fork="true" failonerror="true">
+            <classpath>
+                <pathelement location="${jcov.jar}"/>
+            </classpath>
+            <arg line="-template template.xml -output instr_classes ../../${tutorial.result.dir}/classes/"/>
+        </java>
+
+        <!--running tests-->
+        <java classname="TestDemoApp1" fork="true" failonerror="true">
+            <classpath>
+                <pathelement location="${jcov.file.saver.jar}"/>
+                <pathelement location="../../${tutorial.result.dir}/test_classes"/>
+                <pathelement location="instr_classes"/>
+            </classpath>
+            <sysproperty key="jcov.template" value="template.xml"/>
+            <sysproperty key="jcov.file" value="result.xml"/>
+        </java>
+
+        <java classname="TestDemoApp2" fork="true" failonerror="true">
+            <classpath>
+                <pathelement location="${jcov.file.saver.jar}"/>
+                <pathelement location="../../${tutorial.result.dir}/test_classes"/>
+                <pathelement location="instr_classes"/>
+            </classpath>
+            <sysproperty key="jcov.template" value="template.xml"/>
+            <sysproperty key="jcov.file" value="result.xml"/>
+        </java>
+
+        <!--generate report-->
+        <java classname="com.sun.tdk.jcov.RepGen" fork="true" failonerror="true">
+            <classpath>
+                <pathelement location="${jcov.jar}"/>
+            </classpath>
+            <arg line="-output coverage/report result.xml"/>
+        </java>
+
+    </target>
+
+</project>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/examples/tutorial/example4/one_command.xml	Wed Aug 06 19:05:02 2014 +0400
@@ -0,0 +1,25 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<project name="JCov_one_command" default="build" basedir=".">
+
+    <property file="../../tutorial.build.properties"/>
+
+    <target name="build">
+    <mkdir dir="classes"/>
+
+    <!--copy product classes not to touch other examples-->
+    <copy todir="classes">
+        <fileset dir="../../${tutorial.result.dir}/classes/"/>
+    </copy>
+
+    <!--get coverage for test using one jcov command-->
+    <java classname="com.sun.tdk.jcov.JCov" fork="true" failonerror="true">
+        <classpath>
+            <pathelement location="${jcov.jar}"/>
+        </classpath>
+        <arg line="-pro ${basedir}${file.separator}classes -out coverage -command &quot;${java_home}${file.separator}bin${file.separator}java
+ -cp ${jcov.network.saver.jar}${path.separator}${basedir}${file.separator}classes${path.separator}${basedir}${file.separator}..${file.separator}test_classes TestDemoApp1&quot;"/>
+    </java>
+
+    </target>
+
+</project>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/examples/tutorial/example5/jcov_ant_tasks.xml	Wed Aug 06 19:05:02 2014 +0400
@@ -0,0 +1,44 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<project name="JCov_ant_task" default="build" basedir=".">
+
+    <property file="../../tutorial.build.properties"/>
+    <taskdef name="jcovTasks" classname="com.sun.tdk.jcov.ant.AllTasks" classpath="${basedir}${file.separator}${jcov.jar}"/>
+
+    <target name="build">
+
+        <mkdir dir="instr_classes"/>
+
+        <jcovTasks/>
+        <!--instrument classes-->
+        <instrument productdir="../../${tutorial.result.dir}/classes/" destdir="instr_classes" outtemplate="template.xml">
+            <implantTo path="." implantRT="${jcov.network.saver.jar}"/>
+        </instrument>
+
+        <!--start grabber-->
+        <grabber output="result.xml" template="template.xml"/>
+
+
+        <!--running tests-->
+        <java classname="TestDemoApp1" fork="true" failonerror="true">
+            <classpath>
+                <pathelement location="${jcov.network.saver.jar}"/>
+                <pathelement location="../../${tutorial.result.dir}/test_classes"/>
+                <pathelement location="instr_classes"/>
+            </classpath>
+        </java>
+
+        <java classname="TestDemoApp2" fork="true" failonerror="true">
+            <classpath>
+                <pathelement location="${jcov.network.saver.jar}"/>
+                <pathelement location="../../${tutorial.result.dir}/test_classes"/>
+                <pathelement location="instr_classes"/>
+            </classpath>
+        </java>
+
+        <!--stop grabber-->
+        <grabber-manager command="kill"/>
+        <report output="coverage/report" jcovfile="result.xml"/>
+
+    </target>
+
+</project>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/examples/tutorial/example6/jcov_scales.xml	Wed Aug 06 19:05:02 2014 +0400
@@ -0,0 +1,65 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<project name="JCov_scales" default="build" basedir=".">
+    <property file="../../tutorial.build.properties"/>
+
+    <target name="build">
+
+    <!--instrument classes-->
+    <java classname="com.sun.tdk.jcov.Instr" fork="true" failonerror="true">
+        <classpath>
+            <pathelement location="${jcov.jar}"/>
+        </classpath>
+        <arg line="-template template.xml -output instr_classes ../../${tutorial.result.dir}/classes/"/>
+    </java>
+
+    <parallel>
+    <!--start grabber-->
+    <java classname="com.sun.tdk.jcov.Grabber" fork="true" failonerror="true">
+        <classpath>
+            <pathelement location="${jcov.jar}"/>
+        </classpath>
+        <arg line="-template template.xml -outtestlist testlist.txt -o result.xml"/>
+    </java>
+
+    <sequential>
+
+        <!--running tests-->
+        <java classname="TestDemoApp1" fork="true" failonerror="true">
+            <classpath>
+                <pathelement location="${jcov.network.saver.jar}"/>
+                <pathelement location="../../${tutorial.result.dir}/test_classes"/>
+                <pathelement location="instr_classes"/>
+            </classpath>
+            <jvmarg value="-Djcov.testname=TestDemoApp1"/>
+        </java>
+
+        <java classname="TestDemoApp2" fork="true" failonerror="true">
+            <classpath>
+                <pathelement location="${jcov.network.saver.jar}"/>
+                <pathelement location="../../${tutorial.result.dir}/test_classes"/>
+                <pathelement location="instr_classes"/>
+            </classpath>
+            <jvmarg value="-Djcov.testname=TestDemoApp2"/>
+        </java>
+
+        <!--stop grabber-->
+        <java classname="com.sun.tdk.jcov.GrabberManager" fork="true">
+            <classpath>
+                <pathelement location="${jcov.jar}"/>
+            </classpath>
+            <arg line="-kill"/>
+        </java>
+
+        <!--generate report-->
+        <java classname="com.sun.tdk.jcov.RepGen" fork="true" failonerror="true">
+            <classpath>
+                <pathelement location="${jcov.jar}"/>
+            </classpath>
+            <arg line="-output coverage/report -tests testlist.txt -testsinfo -src ${basedir}/../../${tutorial.result.dir}/../src  result.xml"/>
+        </java>
+    </sequential>
+    </parallel>
+
+    </target>
+
+</project>
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/examples/tutorial/src/com/oracle/demoapp/Plane.java	Wed Aug 06 19:05:02 2014 +0400
@@ -0,0 +1,39 @@
+package com.oracle.demoapp;
+
+import com.oracle.demoapp.figures.abstractpack.Figure;
+
+import java.util.ArrayList;
+
+public class Plane {
+
+    ArrayList<Figure> figures;
+
+    public Plane(){
+        figures = new ArrayList<Figure>();
+    }
+
+    public void addFigure(Figure figure){
+        figures.add(figure);
+    }
+
+    public double countRedFiguresArea(){
+        double result = 0;
+        for (Figure figure : figures){
+            if ("red".equals(figure.getColorName().toLowerCase())){
+                result+=figure.getArea();
+            }
+        }
+        return result;
+    }
+
+    public double countGreenFiguresArea(){
+        double result = 0;
+        for (Figure figure : figures){
+            if ("green".equals(figure.getColorName().toLowerCase())){
+                result+=figure.getArea();
+            }
+        }
+        return result;
+    }
+
+}
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/examples/tutorial/src/com/oracle/demoapp/figures/Disk.java	Wed Aug 06 19:05:02 2014 +0400
@@ -0,0 +1,18 @@
+package com.oracle.demoapp.figures;
+
+import com.oracle.demoapp.figures.abstractpack.Figure;
+
+public class Disk extends Figure {
+
+    private int length;
+
+    public Disk(int l, String color){
+        length = l;
+        setColorName(color);
+    }
+
+    @Override
+    public double getArea() {
+        return Math.PI*length*length;
+    }
+}
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/examples/tutorial/src/com/oracle/demoapp/figures/Square.java	Wed Aug 06 19:05:02 2014 +0400
@@ -0,0 +1,18 @@
+package com.oracle.demoapp.figures;
+
+import com.oracle.demoapp.figures.abstractpack.Figure;
+
+public class Square extends Figure {
+
+    private int length;
+
+    public Square(int l, String color){
+        length = l;
+        setColorName(color);
+    }
+
+    @Override
+    public double getArea() {
+        return length * length;
+    }
+}
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/examples/tutorial/src/com/oracle/demoapp/figures/abstractpack/Figure.java	Wed Aug 06 19:05:02 2014 +0400
@@ -0,0 +1,20 @@
+package com.oracle.demoapp.figures.abstractpack;
+
+public abstract class Figure{
+
+    private String colorName;
+
+    public Figure(){
+    }
+
+    public String getColorName(){
+        return colorName;
+    }
+
+    public void setColorName(String colorName){
+        this.colorName = colorName;
+    }
+
+    public abstract double getArea();
+
+}
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/examples/tutorial/test/TestDemoApp1.java	Wed Aug 06 19:05:02 2014 +0400
@@ -0,0 +1,22 @@
+import com.oracle.demoapp.Plane;
+import com.oracle.demoapp.figures.Disk;
+import com.oracle.demoapp.figures.Square;
+
+public class TestDemoApp1{
+
+    public static void main(String[] args){
+        Plane plane = new Plane();
+        Square square = new Square(2, "Red");
+        Disk disc = new Disk(3, "Green");
+        plane.addFigure(square);
+        plane.addFigure(disc);
+
+        if (plane.countRedFiguresArea() != 4) {
+            throw new RuntimeException("TestDemoApp1 test failed!");
+        } else {
+            System.out.println("TestDemoApp1 test passed");
+        }
+
+    }
+
+}
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/examples/tutorial/test/TestDemoApp2.java	Wed Aug 06 19:05:02 2014 +0400
@@ -0,0 +1,16 @@
+import com.oracle.demoapp.Plane;
+
+public class TestDemoApp2{
+
+    public static void main(String[] args){
+        Plane plane = new Plane();
+
+        if (plane.countGreenFiguresArea() != 0) {
+            throw new RuntimeException("TestDemoApp2 test failed!");
+        } else {
+            System.out.println("TestDemoApp2 test passed");
+        }
+
+    }
+
+}
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/examples/tutorial/tutorial.build.properties	Wed Aug 06 19:05:02 2014 +0400
@@ -0,0 +1,9 @@
+# relative path to output directory
+tutorial.result.dir = DEMOAPP_BUILD
+# relative path to jcov build directory
+jcov.result.dir = ../../../../JCOV_BUILD/jcov_2.0
+jcov.jar = ${jcov.result.dir}/jcov.jar
+jcov.network.saver.jar = ${jcov.result.dir}/jcov_network_saver.jar
+jcov.file.saver.jar = ${jcov.result.dir}/jcov_file_saver.jar
+
+java_home = ${java.home}
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/examples/tutorial/tutorial.build.xml	Wed Aug 06 19:05:02 2014 +0400
@@ -0,0 +1,64 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<project name="DemoApp" default="build" basedir=".">
+
+    <property file="tutorial.build.properties"/>
+
+    <target name="prepare">
+        <delete dir="${tutorial.result.dir}"/>
+        <mkdir dir="${tutorial.result.dir}"/>
+        <mkdir dir="${tutorial.result.dir}/classes"/>
+        <mkdir dir="${tutorial.result.dir}/test_classes"/>
+
+        <copy todir="${tutorial.result.dir}">
+            <fileset dir=".">
+                <include name="example**/*"/>
+            </fileset>
+        </copy>
+
+    </target>
+
+    <target name="build_app"
+            depends="prepare">
+        <javac encoding="iso-8859-1" debug="true" target="1.5" source="1.5"
+               srcdir="src"
+               destdir="${tutorial.result.dir}/classes">
+        </javac>
+
+        <jar destfile="${tutorial.result.dir}/demoapp.jar"
+             basedir="${tutorial.result.dir}/classes"
+             index="false">
+            <manifest>
+                <attribute name="Built-By" value="${user.name}"/>
+            </manifest>
+        </jar>
+    </target>
+
+    <target name="test_app">
+        <javac encoding="iso-8859-1" debug="true" target="1.5" source="1.5"
+               srcdir="test"
+               destdir="${tutorial.result.dir}/test_classes"
+               classpath="${tutorial.result.dir}/demoapp.jar">
+        </javac>
+
+        <java classname="TestDemoApp1" fork="true" failonerror="true">
+            <classpath>
+                <pathelement location="${tutorial.result.dir}/test_classes"/>
+                <pathelement location="${tutorial.result.dir}/demoapp.jar"/>
+            </classpath>
+        </java>
+
+        <java classname="TestDemoApp2" fork="true" failonerror="true">
+            <classpath>
+                <pathelement location="${tutorial.result.dir}/test_classes"/>
+                <pathelement location="${tutorial.result.dir}/demoapp.jar"/>
+            </classpath>
+        </java>
+
+    </target>
+
+    <target name="build"
+            depends="build_app, test_app"
+            description="demo application build.">
+    </target>
+
+</project>
\ No newline at end of file