Package org.fest.swing.test.swing

Examples of org.fest.swing.test.swing.TestMdiWindow


    }
  }

  @Test
  public void should_pass_if_JInternalFrame_is_resizable() {
    TestMdiWindow w = TestMdiWindow.createNewWindow(getClass());
    robot.showWindow(w);
    checkCanResize(w.internalFrame());
  }
View Full Code Here


    checkCanResize(w.internalFrame());
  }

  @Test
  public void should_pass_if_JInternalFrame_is_resizableAndDisabled() {
    TestMdiWindow w = TestMdiWindow.createNewWindow(getClass());
    robot.showWindow(w);
    disable(w.internalFrame());
    checkCanResize(w.internalFrame());
  }
View Full Code Here

    checkCanResize(w.internalFrame());
  }

  @Test
  public void should_fail_if_JInternalFrame_is_not_resizable() {
    TestMdiWindow w = TestMdiWindow.createNewWindow(getClass());
    robot.showWindow(w);
    JInternalFrame i = w.internalFrame();
    makeNotResizable(i);
    robot.waitForIdle();
    try {
      checkCanResize(i);
      failWhenExpectingException();
View Full Code Here

    });
  }

  @Test
  public void should_fail_if_JInternalFrame_is_resizable_but_not_showing_on_the_screen() {
    TestMdiWindow w = TestMdiWindow.createNewWindow(getClass());
    try {
      checkCanResize(w.internalFrame());
      failWhenExpectingException();
    } catch (IllegalStateException e) {
      assertThatErrorCauseIsNotShowingComponent(e);
    }
  }
View Full Code Here

public class JInternalFrameSetIconTask_setIcon_Test extends RobotBasedTestCase {
  private JInternalFrame internalFrame;

  @Override
  protected void onSetUp() {
    TestMdiWindow window = TestMdiWindow.createNewWindow(getClass());
    internalFrame = window.internalFrame();
  }
View Full Code Here

public class JInternalFrameIconQuery_isIconified_Test extends RobotBasedTestCase {
  private JInternalFrame internalFrame;

  @Override
  protected void onSetUp() {
    TestMdiWindow window = TestMdiWindow.createNewWindow(getClass());
    internalFrame = window.internalFrame();
  }
View Full Code Here

public class JInternalFrameCloseTask_close_Test extends RobotBasedTestCase {
  private JInternalFrame internalFrame;

  @Override
  protected void onSetUp() {
    TestMdiWindow window = TestMdiWindow.createNewWindow(getClass());
    internalFrame = window.internalFrame();
    robot.showWindow(window);
    assertThat(window.internalFrame().isVisible()).isTrue();
  }
View Full Code Here

    }
  }

  @Test
  public void should_return_parent_of_JInternalFrame() {
    TestMdiWindow window = TestMdiWindow.createNewWindow(getClass());
    JInternalFrame internalFrame = window.internalFrame();
    try {
      assertThat(findParent(finder, internalFrame)).isNotNull().isSameAs(desktopPaneOf(internalFrame));
    } finally {
      window.destroy();
    }
  }
View Full Code Here

public class JInternalFrameSetMaximumTask_setMaximum_Test extends RobotBasedTestCase {
  private JInternalFrame internalFrame;

  @Override
  protected void onSetUp() {
    TestMdiWindow window = TestMdiWindow.createNewWindow(getClass());
    internalFrame = window.internalFrame();
  }
View Full Code Here

  }

  @Test
  public void should_return_iconified_JInternalFrames_if_Component_is_JDesktopPane() {
    ScreenLock.instance().acquire(this);
    final TestMdiWindow window = createAndShowNewWindow(getClass());
    iconify(window.internalFrame());
    Collection<Component> children = execute(new GuiQuery<Collection<Component>>() {
      @Override
      protected Collection<Component> executeInEDT() {
        return finder.nonExplicitChildrenOf(window.desktop());
      }
    });
    try {
      assertThat(children).containsOnly(window.internalFrame());
    } finally {
      try {
        window.destroy();
      } finally {
        ScreenLock.instance().release(this);
      }
    }
  }
View Full Code Here

TOP

Related Classes of org.fest.swing.test.swing.TestMdiWindow

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.