Replace "with" (deprecated) usage with "browser.evaluate"

While working on a fix for #64 I've also did a major rewrite to `wait` functionality implementation in the driver in general. Now it doesn't use `with` construct in JavaScript.