testing : Java Glossary

*0-9ABCDEFGHIJKLMNOPQRSTUVWXYZ (all)

testing
There are two basic methods of testing your code:
  1. Unit testing: or white box testing. You write little routines to exhaustively test each execution branch of your method. I often refer to such a suite as a test harness. You test each method in isolation. Unit tests are best at finding implementation errors, such as off-by-one loops. Tools such as JUNIT (Java Unit test) can help you compose these tests.
  2. Black-box testing: or system level testing. This is best at finding integration errors. The tester deliberately does not look at how a function is implemented. He is out to catch miscommunications between programmers on how to use each others’ classes. The tester avoids looking at the code to avoid falling into the same traps and presumptions the programmers did.
In a simple case, your test method can be the main method of the class you are testing with the body of the method enclosed in:
if ( DEBUGGING )
where DEBUGGING is a static final boolean. This code has a dual purpose of exercising the methods and showing some sample uses and expected outputs.

For more complex classes, you use a tool like JUnit.

<xml-unit>
Cactus
DBUnit
FitNesse
Hansel
JFunc
JTestCase
JUnit
JUnitPerf
JUnitPP
regression
Solex: lets you replay Internet conversations for regression testing
TagUnit
TestNG: (Daniel Dyer’s favourite)

This page is posted
on the web at:

http://mindprod.com/jgloss/testing.html

Optional Replicator mirror
of mindprod.com
on local hard disk J:

J:\mindprod\jgloss\testing.html
Canadian Mind Products
Please the feedback from other visitors, or your own feedback about the site.
Contact Roedy. Please feel free to link to this page without explicit permission.

IP:[65.110.21.43]
Your face IP:[3.17.6.75]
You are visitor number