Reliability Statistics with GERT
|
GERT (Good Enough Reliability Tool) is an Eclipse plug-in that is used to provide reliability estimations and feedback on the quality of test coverage in an application. GERT provides test coverage infomation by analysing source and test code to determine how well your tests cover the source code. Reliability is based on the STREW metric suite that uses a set of easy-to-measure internal metrics that provide feedback on the thoroughness of a testing effort and can be used as early indication of the external measure of system reliability |
Download the GERT plug-in. Extract GERT to your Eclipse install directory (on the machines in the lab it is C:\Program Files\eclipse\). Once you have extracted Eclipse go to your Eclipse directory and verify there is an edu.ncsu.csc.gert_3.0.0/ directory in the plugins/ directory. You may also use the download site for GERT, located at: http://gert.sf.net/. Start (or restart) Eclipse. This will add the plug-in the the Eclipse platform. To make sure the GERT plug-in was added, select Window > Open Perspective > Other... Choose The GERT perspective offers three new views:
|
To get to the GERT preferences page select Window > Preferences. Select GERT from the tree on the left of the preferences page. 3.1 The general GERT preferences allow the user to enter the number of requirements on the project being measured, and change the colors that highlight the range of the statistic. There are also two check boxes that allow for the STREW model and a custom model to be displayed. 3.2 The coverage preferences allow for the selection of a source and output folder for the project. This was the source and class files can be found and metrics can be computed on them. 3.3 The custom metric preference pages allows for the creation of a new metric. Several variables are listed that the GERT plug-in already calculates for you and can be used in the custom metric. 3.4 The STREW preferences allows for information about the STREW model, like variable coefficients and valid ranges, to be specified. |
|||
The Reliability Files view contains a listing of source and test files that will have reliability and coverage sweep run on them. This view contains two folders: Source Files and Test Files. To add a file to these folders, right click on the file in the Package Explorer and select Add File(s) for Reliability Testing. The file will be added to the appropriate folder under the Reliability Files view. (All test files must have the proper JUnit naming scheme of ClassBeingTestedTest). The tool bar |
To add a source or test file to these folders, right click on the file in the Package Explorer and select Add File(s) for Reliability Testing. The file will be added to the appropriate folder under the Reliability Files view. (All test files must have the proper JUnit naming scheme of ClassBeingTestedTest |
| The Reliabilty Metrics view contains graphical output describing the STREW statistic and any custom metric that you create. In order to view a custom metric's results, make sure that Use custom expression model is checked in the GERT preferences. |
The Reliabity Ratios view list coverage metrics and statistics about each class and test class that has been selected to be run in GERT. The Metrics Total box contains the following metrics (LOC represents lines of code):
The colors of the text in the Metrics Totals box describes if the metric is within, above, or below required bounds. The color can be changed in the GERT preference. The Source Classes area contains statistics about an individual selected source files including LOC, classes (there is more that one class listed if there are inner classes), conditionals, statement coverage percentage, and branch coverage percentage. The Test Classes area contains statistcs about an individual selected test file including LOC, classes (there is more than one class listed if there are inner classes), test methods, and asserts. Note: In order to switch between GERT and running JUnit tests, make sure that jcoverage.jar (located in the GERT plug-in directory) is on your project's build path. If there are any other errors, change your code and resave, thus recompiling your code. You should be able to run JUnit then. If you have any other problems, select Project > Clear.... |
| GERT - Good Enough Reliability Tool |