Make rethrow() separate from wait()

Now you must call rethrow() on the TestBackgroundJob after wait() finishes.
This fixes an assertion failure in boost::mutex when you destroy a
background job while it is still running.