I am trying to launch the browser with the simple code , the problem i am facing is browser window is getting open but it is showing data and it is not hitting the google url.
public class SeleniumBrowserLaunch {
public static void main (String[] args) {
System.setProperty("webdriver.chrome.driver", "D:\\Study_material\\Selenium_setup\\chromedriver_win32\\chromedriver.exe");
WebDriver driver = new ChromeDriver();
driver.manage().window().maximize();
driver.get("https://www.google.com/");
}
}
Error i am getting is this: java.io.IOException: Invalid Status code=403 text=Forbidden Unable to establish websocket connection to http://localhost:58703/devtools/browser/83403c9d-252d-40af-b350-a36926a5a929
Below are the screenshots for errors.
enter image description here enter image description here
I need help to resolve this error. Thanks in advance.