@Test public void maximizeButtonShouldWorkOnTabbedPanel() throws Exception { MaximizeTestScreenWrapper tabPanelScreen4 = new MaximizeTestScreenWrapper(driver, MaximizeTestPerspective.TAB_PANEL_SCREEN_4_ID); Dimension reportedSizeBefore = tabPanelScreen4.getReportedSize(); tabPanel.clickMaximizeButton(); Dimension reportedSizeAfter = tabPanelScreen4.getReportedSize(); assertBigger(reportedSizeBefore, reportedSizeAfter); assertObscuredBy(tabPanel, listPanel); assertObscuredBy(tabPanel, simplePanel); }
@Test public void maximizedTabPanelShouldTrackWindowSize() throws Exception { MaximizeTestScreenWrapper tabPanelScreen4 = new MaximizeTestScreenWrapper(driver, MaximizeTestPerspective.TAB_PANEL_SCREEN_4_ID); tabPanel.clickMaximizeButton(); Dimension originalMaximizedSize = tabPanelScreen4.getReportedSize(); driver.manage().window().setSize(new Dimension(WINDOW_WIDTH + 50, WINDOW_HEIGHT - 40)); new WebDriverWait(driver, 5) .until( reportedSizeIs( tabPanelScreen4, new Dimension( originalMaximizedSize.width + 50, originalMaximizedSize.height - 40))); }