Finish testing navigator

Has to change the actual window.location, seems like the simplest way without
changing the lib to be more complicated for the sake of tests.