コード例 #1
0
  @Before
  public void setUp() throws PatrimonioException, SQLException {
    robot = BasicRobot.robotWithNewAwtHierarchy();
    robot.settings().delayBetweenEvents(5);

    window = new FrameFixture(robot, new Main2());
    window.show(new Dimension(900, 500)); // shows the frame to test

    sala = new Sala("code", "Sala para testes de aceitacao", "123");
    SalaDAO.getInstance().incluir(sala);

    index = SalaDAO.getInstance().buscarTodos().size() - 1;

    window.button("Sala").click();
    dialog = window.dialog("SalaView");
  }
コード例 #2
0
 @After
 public void tearDown() throws SQLException, PatrimonioException {
   if (sala != null) SalaDAO.getInstance().excluir(sala);
   window.cleanUp();
 }