How to Maximize browser window using selenium Web Driver
import org.openqa.selenium.firefox.FirefoxDriver; // If you are using Firefox Browser
import org.openqa.selenium.chrome.ChromeDriver;// If you are using Chrome Browser
import org.openqa.selenium.ie.InternetExplorerDriver; // If you are using IE
import java.util.concurrent.TimeUnit;
public class MaximizeWindow {
public static void main(String[] args)
{
FirefoxDriver driver = new FirefoxDriver();
driver.get("https://www.linkedin.com");
driver.manage().timeouts().implicitlyWait(10, TimeUnit.SECONDS);
driver.manage().window().maximize(); // for maximize window
}
}
import org.openqa.selenium.firefox.FirefoxDriver; // If you are using Firefox Browser
import org.openqa.selenium.chrome.ChromeDriver;// If you are using Chrome Browser
import org.openqa.selenium.ie.InternetExplorerDriver; // If you are using IE
import java.util.concurrent.TimeUnit;
public class MaximizeWindow {
public static void main(String[] args)
{
FirefoxDriver driver = new FirefoxDriver();
driver.get("https://www.linkedin.com");
driver.manage().timeouts().implicitlyWait(10, TimeUnit.SECONDS);
driver.manage().window().maximize(); // for maximize window
}
}
No comments:
Post a Comment