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

Examples of org.eclipse.swtbot.swt.finder.widgets.SWTBotToolbarButton.click()


        // just a workaround till view.toolbarButton() is fixed
        Matcher matcher = allOf( widgetOfType( ToolItem.class ), withTooltip( "Refresh" ), withStyle( SWT.PUSH,
            "SWT.PUSH" ) );
        SWTBotToolbarButton button = new SWTBotToolbarButton( ( ToolItem ) new SWTWorkbenchBot().widget( matcher, 0 ),
            matcher );
        button.click();

        return view.bot().styledText().getText();
    }

}
View Full Code Here


        //view.toolbarButton( "Refresh" ).click();
        // just a workaround till view.toolbarButton() is fixed
        Matcher matcher = allOf( widgetOfType( ToolItem.class ), withTooltip( "Refresh" ), withStyle( SWT.PUSH,
            "SWT.PUSH" ) );
        SWTBotToolbarButton button = new SWTBotToolbarButton( ( ToolItem ) new SWTWorkbenchBot().widget( matcher, 0 ), matcher );
        button.click();

        return view.bot().styledText().getText();
    }
}
View Full Code Here

        // just a workaround till view.toolbarButton() is fixed
        Matcher matcher = allOf( widgetOfType( ToolItem.class ), withTooltip( "Refresh" ), withStyle( SWT.PUSH,
            "SWT.PUSH" ) );
        SWTBotToolbarButton button = new SWTBotToolbarButton( ( ToolItem ) new SWTWorkbenchBot().widget( matcher, 0 ),
            matcher );
        button.click();

        return view.bot().styledText().getText();
    }

}
View Full Code Here

        return gfmView.getReference().getPart(false).getTitle();
    }
   
    public PreferencesBot showPreferences() {
        SWTBotToolbarButton toolbarButton = UtilityBot.getToolbarButtonWithTooltip(gfmView, "Preferences");
        toolbarButton.click();
        return PreferencesBot.fromActivatedPreferences();
    }
   
    public SWTBotToolbarButton getOnlineButton() {
        return UtilityBot.getToolbarButtonWithTooltip(gfmView, "Online");
View Full Code Here

        assertThat(MarkdownViewBot.isPresent(), is(true));

        assertThat(markdownViewBot.getTitle(), not(is("file1")));
       
        SWTBotToolbarButton reloadButton = markdownViewBot.getReloadButton();
        reloadButton.click();
        SWTUtils.sleep(2000);

        assertThat(markdownViewBot.getTitle(), is("file1"));
       
        markdownViewBot.close();
View Full Code Here

        EditorBot editorBot2 = EditorBot.findByName("file2.md").show();
        SWTUtils.sleep(2000);
        assertThat(markdownViewBot.getTitle(), is("file2"));

        linkedButton.click(); // set unlinked

        editorBot2.close();
        SWTUtils.sleep(2000);
        assertThat(markdownViewBot.getTitle(), is("file2"));
View Full Code Here

        editorBot1.close();
        SWTUtils.sleep(2000);
        assertThat(markdownViewBot.getTitle(), is("file2"));

        linkedButton.click();
        markdownViewBot.close();
        project.delete();
    }

    @Test
View Full Code Here

        assertThat(markdownViewBot.getTitle(), is("*file1"));
        String textHt1 = IOUtils.toString(new FileInputStream(fileHt));
        assertThat(textHt1, containsString(textMd1));
        assertThat(textHt1, not(containsString(textMd2)));

        reloadButton.click();
        SWTUtils.sleep(2000);

        assertThat(markdownViewBot.getTitle(), is("*file1"));
        String textHt2 = IOUtils.toString(new FileInputStream(fileHt));
        assertThat(textHt2, containsString(textMd1));
View Full Code Here

        String textHt2 = IOUtils.toString(new FileInputStream(fileHt));
        assertThat(textHt2, containsString(textMd1));
        assertThat(textHt2, not(containsString(textMd2)));

        onlineButton.click(); // set online
        reloadButton.click();
        SWTUtils.sleep(2000);

        assertThat(markdownViewBot.getTitle(), is("file1"));
        String textHt3 = IOUtils.toString(new FileInputStream(fileHt));
        assertThat(textHt3, containsString(textMd1));
View Full Code Here

    launchSynchronization(Constants.HEAD, trackingBranch, false);

    SWTBotView viewBot = bot.viewByTitle("Synchronize");
    SWTBotToolbarButton pushButton = viewBot.toolbarButton(UIText.GitActionContributor_Push);
    JobJoiner jobJoiner = JobJoiner.startListening(JobFamilies.PUSH, 30, TimeUnit.SECONDS);
    pushButton.click();
    jobJoiner.join();

    String destinationString = repositoryFile.getParentFile().getName() + " - " + "origin";
    SWTBotShell resultDialog = bot.shell(NLS.bind(UIText.PushResultDialog_title, destinationString));
    resultDialog.close();
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. 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.