PhantomJSDriver is not auto-redirecting to a URL

324 Views Asked by At

I have written an automation test using Selenium with C#.

When I am using Chrome driver to automate test then it's working as expected. Code are as below:

 IWebDriver driver = new ChromeDriver();
 driver.Navigate().GoToUrl("https://de.buyvip.com/");

When I am using PhantomJS driver to automate the same test then it's not working as expected. Code are as below:

 IWebDriver driver = new PhantomJSDriver();
 driver.Navigate().GoToUrl("https://de.buyvip.com/");

In Chrome driver, when a user tries to navigate https://de.buyvip.com/ then a user is automatically navigated to the login page.

But in a case of PhantomJSDriver when a user tries to navigate https://de.buyvip.com/ then a user remains on the same page and not automatically redirected to the login page.

0

There are 0 best solutions below