Page Tools:
Wiki Relationships:
Admin Tools:
Projects:testgen4j
(Redirected from Projects:TestGen4J)Home | News | Requirements | Documentation | Screenshots | | Download | Forum | FAQ
About TestGen4J
TestGen is a collection of open-source tools that automatically generates unit test cases. The first released component of TestGen is TestGen4J. TestGen4J automatically generates JUnit test cases from your own Java class files, or source files. Its primary focus is to exercise boundary value testing of the arguments passed to the method. It uses rules, written in a user-configurable XML file, that defines boundary conditions for the data types. The test code is separated from test data with the help of JTestCase.
The test code is generated in a hierarchical manner. A main test suite is generated which invokes test suites of individual classes. The individual class test suite is formed by collection of test methods of that class.
The test data is also organized hierarchically, corresponding to the structure of the test code, in XML format. This XML file actually has data for all unit test cases for each method. JTestCase helps to loop through all the test cases of each method and executing one by one against JUnit.
Objective
TestGen4J should typically be used as metric tool, before you actually perform white box testing on your application. You can model your application's behavior to different sets of data inputs for the arguments in the methods or functions of your application. You can analyze if your application can handle different exceptions and in general if your application really is fault tolerant to all possible combinations of data sets for the data types of the arguments in the methods. Screenshots of building and running the test cases are available here.
Flow chart showing the difference between typical developer testing and TestGen4J
--Maratmu 18:21, 30 September 2005 (PDT)


Testing
