FAQ

  1. Where does UCovered fit in the testing cycle?
  2. Do UCovered/JUnit tests run concurrently?
  3. What is the connection between JUnit's assertions and Java asserts?
  4. What is the relationship between JXCL and Quilt?

Where does UCovered fit in the testing cycle?

After your unit tests. Coverage tests are run when you are satisfied that your software under development passes all its tests. You then run UCovered, which lets you know how thorough that testing has been.

UCovered can also be quite useful in integration tests, where it can track exactly how modules call one another in actual use.

Do UCovered/JUnit tests run concurrently?

No, at least not because of JUnit or UCovered. Each test is started by JUnit. It runs and the results are collected, then the next test is started. UCovered loads classes and provides a report at the end. All of this is fully serialized.

If the tests themselves are multi-threaded, standard JUnit has no way of knowing this, so the results are unpredictable. If the unit that JUnit started returns, JUnit will not wait for any threads to complete. It just starts the next test.

On the other hand, if you need to run multithreaded tests, you can find help in the standard JUnit distribution: junit.extensions.ActiveTestSuite. This class, an extension to TestSuite, runs each test in a separate thread and waits until all have terminated. However, even in this case each test must either be single-threaded or handle its own concurrency correctly.

What is the connection between JUnit's assertions and Java asserts?

There isn't any. Earlier versions of JUnit had an assert method. When Sun introduced assert as a keyword in the Java lanaguage, JUnit had to rename its method to assertTrue. assert is part of the language; assertTrue is a method that throws a JUnit-defined exception.

What is the relationship between JXCL and Quilt?

JXCL 0.6 was a rewrite of an earlier Sourceforge project, Quilt. Development of Quilt was led by David Dixon-Peugh, some of whose test code remains in JXCL. Work on Quilt ended in the fall of 2002. Jim Dixon began a rewrite in June of 2003. The projects forked in October 2003.


This material is copyright 2003 by James David Dixon ("Jim Dixon") and is made available under the Artistic License.