Fixed window.location and removed console.log in test file.