Helper class allowing unit tests to wait till a code in question executes in a separate thread. There is still some element of uncertainty remains, since this implementation simply tries to give other threads enough time to execute, instead of watching for threads activity.
Note that result sampling is done every 300 ms., so if the test succeeds earlier, test case wouldn't have to wait for the whole time period specified by timeout.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.