Package org.eclipse.swtbot.swt.finder.widgets

Examples of org.eclipse.swtbot.swt.finder.widgets.SWTBotTree


    TestUtil.waitUntilTreeHasNodeContainsText(shell.bot(), shell.bot()
        .tree(), "BareRepository2", 10000);
  }

  private void assertHasClonedRepo() throws Exception {
    final SWTBotTree tree = getOrOpenView().bot().tree();
    String text = repositoryFile.getParentFile().getName() + "Cloned";
    TestUtil.waitUntilTreeHasNodeContainsText(bot, tree, text, 10000);
  }
View Full Code Here


    TestUtil.joinJobs(JobFamilies.REPO_VIEW_REFRESH);
    return view;
  }

  protected void assertHasRepo(File repositoryDir) throws Exception {
    final SWTBotTree tree = getOrOpenView().bot().tree();
    final SWTBotTreeItem[] items = tree.getAllItems();
    boolean found = false;
    for (SWTBotTreeItem item : items) {
      if (item.getText().startsWith(
          repositoryDir.getParentFile().getName())) {
        found = true;
View Full Code Here

  private void testPushToOrigin(boolean useRemote) throws Exception {
    Activator.getDefault().getRepositoryUtil().addConfiguredRepository(
        clonedRepositoryFile);
    shareProjects(clonedRepositoryFile);
    SWTBotTree tree = getOrOpenView().bot().tree();
    tree.select(0);

    Repository repository = lookupRepository(clonedRepositoryFile);
    // add the configuration for push
    repository.getConfig().setString("remote", "origin", "push",
        "refs/heads/*:refs/remotes/origin/*");
 
View Full Code Here

    // add the configuration for push from cloned2
    repository.getConfig().setString("remote", "origin", "push",
        "refs/heads/*:refs/heads/*");
    repository.getConfig().save();

    SWTBotTree tree = getOrOpenView().bot().tree();

    String destinationString = clonedRepositoryFile.getParentFile()
        .getName()
        + " - " + "origin";
    String dialogTitle = NLS.bind(UIText.FetchResultDialog_title,
View Full Code Here

   *
   * @throws Exception
   */
  @Test
  public void testExpandFirstLevel() throws Exception {
    SWTBotTree tree = getOrOpenView().bot().tree();
    SWTBotTreeItem item = myRepoViewUtil.getRootItem(tree, repositoryFile)
        .expand();
    SWTBotTreeItem[] children = item.getItems();
    assertEquals("Wrong number of children", 5, children.length);
  }
View Full Code Here

   * @throws Exception
   */
  @Test
  public void testOpen() throws Exception {
    // expand first level
    SWTBotTree tree = getOrOpenView().bot().tree();
    SWTBotTreeItem item = myRepoViewUtil.getRootItem(tree, repositoryFile);
    item.collapse();
    refreshAndWait();
    item = myRepoViewUtil.getRootItem(tree, repositoryFile);
    assertTrue("Item should not be expanded", !item.isExpanded());
View Full Code Here

   *
   * @throws Exception
   */
  @Test
  public void testExpandSymbolicRef() throws Exception {
    SWTBotTree tree = getOrOpenView().bot().tree();
    SWTBotTreeItem item = myRepoViewUtil.getSymbolicRefsItem(tree,
        repositoryFile).expand();
    List<String> children = item.getNodes();
    boolean found = false;
    for (String child : children)
View Full Code Here

   *
   * @throws Exception
   */
  @Test
  public void testExpandWorkDir() throws Exception {
    SWTBotTree tree = getOrOpenView().bot().tree();
    Repository myRepository = lookupRepository(repositoryFile);
    List<String> children = Arrays
        .asList(myRepository.getWorkTree().list());
    List<String> treeChildren = myRepoViewUtil.getWorkdirItem(tree,
        repositoryFile).expand().getNodes();
View Full Code Here

   */
  @Test
  public void testContextMenuRepository() throws Exception {
    // We just check if the dialogs open, the actual commit and import projects
    // is tested elsewhere
    SWTBotTree tree = getOrOpenView().bot().tree();
    SWTBotTreeItem item = myRepoViewUtil.getRootItem(tree, repositoryFile);
    item.select();
    assertClickOpens(tree,
        myUtil.getPluginLocalizedValue("RepoViewCommit.label"),
        UIText.CommitDialog_CommitChanges);
View Full Code Here

   *
   * @throws Exception
   */
  @Test
  public void testShowProperties() throws Exception {
    SWTBotTree tree = getOrOpenView().bot().tree();
    SWTBotTreeItem item = myRepoViewUtil.getRootItem(tree, repositoryFile);
    item.select();
    ContextMenuHelper.clickContextMenuSync(tree,
        myUtil.getPluginLocalizedValue("ShowIn"),
        "Properties");
View Full Code Here

TOP

Related Classes of org.eclipse.swtbot.swt.finder.widgets.SWTBotTree

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.