Added a unit test for worker timeouts. Set the timeout used in the
main worker tests to 1 second to ensure that the final worker stop
test finishes in reasonable time.