Throw TestFailedOnTimeoutException instead of plain Exception on timeout. Fixes #771

Throw TestFailedOnTimeoutException instead of plain Exception on timeout. Fixes #771