public IWebDriver InitDriver(IWebDriver driver, Iconfig Config) { Console.WriteLine("upali"); Console.WriteLine("Inside InitDriver"); Console.WriteLine("browser type:" + Config.GetBrowser()); switch (Config.GetBrowser()) { case BrowserType.Firefox: driver = GetFirefoxDriver(); break; case BrowserType.Chrome: // driver = GetChromeDriver(); ChromeOptions chromeOptions = new ChromeOptions(); chromeOptions.AddArgument("--start-maximized"); driver = new ChromeDriver(chromeOptions); break; case BrowserType.ChromeForCEF: driver = GetChromeDriverForCEFApp(Config.GetCEFAppPath()); break; case BrowserType.IExplorer: driver = GetIEDriver(); break; default: throw new NoDriverFound("Driver not found : " + Config.GetBrowser().ToString()); } return(driver); }
public IWebDriver InitDriver(IWebDriver driver, Iconfig config) { switch (config.GetBrowser()) { case BrowserType.Firefox: driver = GetFirefoxDriver(); break; case BrowserType.Chrome: driver = GetChromeDriver(); break; case BrowserType.iChrome: driver = GetIncognitoChromeDriver(); break; case BrowserType.IExplorer: driver = GetIEDriver(); break; default: throw new NoDriverFound("Driver not found : " + config.GetBrowser()); } return(driver); }
public IWebDriver InitDriver(IWebDriver driver, Iconfig Config) { Console.WriteLine("upali"); Console.WriteLine("Inside InitDriver"); Console.WriteLine("browser type:" + Config.GetBrowser()); switch (Config.GetBrowser()) { case BrowserType.Firefox: driver = GetFirefoxDriver(); break; case BrowserType.Chrome: driver = GetChromeDriver(); break; case BrowserType.IExplorer: driver = GetIEDriver(); break; default: throw new NoDriverFound("Driver not found : " + Config.GetBrowser().ToString()); } return(driver); }