Selenium Automation Tester using JavaScript Mock test