Completed unit testing threads example code.