コード例 #1
0
  /** Check that the creation tools are accessible on contextual menu */
  private void checkContextualMenuTableRepresentation() {
    // Reduce timeout
    final long oldTimeout = SWTBotPreferences.TIMEOUT;
    table.getTable().getTreeItem(CLASS1).select().contextMenu("Create Class");
    table.getTable().getTreeItem(CLASS1).select().contextMenu("line");
    try {
      SWTBotPreferences.TIMEOUT = 500;
      table.getTable().getTreeItem(CLASS1).select().contextMenu(CREATION_TOOL);
      fail("This tool should not be present");

    } catch (TimeoutException tme) {
      // DO NOTHINGS, it's the good behavior
    } finally {
      SWTBotPreferences.TIMEOUT = oldTimeout;
    }
  }
コード例 #2
0
 private void checkContextualMenuMenuTableRepresentationRefreshed() {
   table.getTable().setFocus();
   table.getTable().getTreeItem(CLASS1).select().contextMenu("Create Class");
   table.getTable().getTreeItem(CLASS1).select().contextMenu("line");
   table.getTable().getTreeItem(CLASS1).select().contextMenu(CREATION_TOOL);
 }