How to minimize the browser window in Selenium WebDriver 3

前端 未结 7 1022
南方客
南方客 2021-01-05 18:14

After maximizing the window by driver.manage().window().maximize();, how do I minimize the browser window in Selenium WebDriver with Java?

相关标签:
7条回答
  • 2021-01-05 18:41

    Try this. It should work.

    Dimension n = new Dimension(360, 592);  
    driver.manage().window().setSize(n);
    
    0 讨论(0)
提交回复
热议问题