Fixes the wait() test helper which was broken since the introduction of the async router

For some reason it seems like the wait() helper was never updated after the router was made asynchronous. This fix alone made my integration tests way more stable.