JUnit test framework provides an excellent way to formalize your test code. But due to its "none-input-param, none-return" design, generally you need to hard-code all test data for each testing method. And for each test cases of one unit test, you need to change test code, recompile it, and run it.
JTestCase that helps you in seperating test data from test code. You can organize all your test cases of multiple unit tests into one data file - an XML file, and bulk-load them into memory via sets of easy-to-use APIs that JTestCase provides. In a word, JTestCase provides a way for java unit tests to be test-case-oriented and full-test-automatable.
Here is presented an introductory example to see how jtestcase works; this example is not a complete one (in the Getting Started section you can find a complete working example).Suppose you have a method to sum two integers that you need to test.
In your junit test case, use the jtestcase API to pull data from the xml file; make a call to the method you want to test and make the assertions defined in the xml file using jtestcase assertion facility:
If the result of the method call
myCalculator.sum() equals 3 the test is asserted positively;
This is the main idea behind the jtestcase tool. If you want to get more info, read in this
site using the sidebar and/or contact the mailing lists.