Add timeout in wait helpers