Added support for waitForUrl(url, query, timeout)