reflect redirected URL before applying page contents

I've swapped the order of the calls to `changePage` and `reflectRedirectedUrl`. This was causing issues with scripts  called during the `executeScriptTags` reading from `window.location.href` after a redirect. I've added a simple test case which demonstrates this.