package test;
import org.openqa.selenium.Dimension;
import org.openqa.selenium.WebDriver;
import org.openqa.selenium.chrome.ChromeDriver;
import org.testng.annotations.Test;
public class BrowserOperation {
@Test
public void test() throws InterruptedException{
System.setProperty(“webdriver.chrome.driver”, “D:/01 Learn WebDriver/chromedriver.exe”);
WebDriver dr = new ChromeDriver();
dr.manage().window().maximize();
//Dimension size = new Dimension(320,480);
//dr.manage().window().setSize(size);
Thread.sleep(3000);
dr.quit();
}
}
原创文章,作者:ItWorker,如若转载,请注明出处:https://blog.ytso.com/193194.html