Search in sources :

Example 11 with DefaultCombo

use of org.eclipse.reddeer.swt.impl.combo.DefaultCombo in project linuxtools by eclipse.

the class DockerConnection method openImageSearchDialog.

public void openImageSearchDialog(String imageName, String imageTag, String dockerRegister) {
    refreshImages();
    treeViewerHandler.getTreeItem(item, "Images").select();
    new ContextMenu().getItem("Pull...").select();
    new WaitUntil(new ShellIsAvailable("Pull Image"), TimePeriod.DEFAULT);
    // select register
    if (dockerRegister != null) {
        Combo combo = new DefaultCombo();
        combo.setSelection(dockerRegister);
    }
    new LabeledText(IMAGE_NAME_LABEL_DIALOG).setFocus();
    new LabeledText(IMAGE_NAME_LABEL_DIALOG).setText(imageTag == null ? imageName : imageName + ":" + imageTag);
    new PushButton("Search...").click();
}
Also used : ShellIsAvailable(org.eclipse.reddeer.swt.condition.ShellIsAvailable) DefaultCombo(org.eclipse.reddeer.swt.impl.combo.DefaultCombo) LabeledText(org.eclipse.reddeer.swt.impl.text.LabeledText) ContextMenu(org.eclipse.reddeer.swt.impl.menu.ContextMenu) Combo(org.eclipse.reddeer.swt.api.Combo) DefaultCombo(org.eclipse.reddeer.swt.impl.combo.DefaultCombo) WaitUntil(org.eclipse.reddeer.common.wait.WaitUntil) PushButton(org.eclipse.reddeer.swt.impl.button.PushButton)

Example 12 with DefaultCombo

use of org.eclipse.reddeer.swt.impl.combo.DefaultCombo in project linuxtools by eclipse.

the class DockerImage method pushImage.

public void pushImage(String registryAccount, boolean forceTagging, boolean keepTaggedImage) {
    select();
    new ContextMenu().getItem("Push...").select();
    new DefaultShell("Push Image");
    Combo combo = new DefaultCombo();
    combo.setSelection(registryAccount);
    new CheckBox("Force tagging image with selected registry").toggle(forceTagging);
    new CheckBox("Keep tagged image upon completion").toggle(keepTaggedImage);
    new FinishButton().click();
}
Also used : DefaultCombo(org.eclipse.reddeer.swt.impl.combo.DefaultCombo) FinishButton(org.eclipse.reddeer.swt.impl.button.FinishButton) DefaultShell(org.eclipse.reddeer.swt.impl.shell.DefaultShell) CheckBox(org.eclipse.reddeer.swt.impl.button.CheckBox) ContextMenu(org.eclipse.reddeer.swt.impl.menu.ContextMenu) Combo(org.eclipse.reddeer.swt.api.Combo) DefaultCombo(org.eclipse.reddeer.swt.impl.combo.DefaultCombo)

Example 13 with DefaultCombo

use of org.eclipse.reddeer.swt.impl.combo.DefaultCombo in project linuxtools by eclipse.

the class ImageRunResourceVolumesVariablesPage method addDataVolumeToContainer.

public void addDataVolumeToContainer(String containerPath, String containerName) {
    new PushButton(0, new WithTextMatcher("Add...")).click();
    new LabeledText("Container path:").setText(containerPath);
    new RadioButton("Mount a data volume container").click();
    new DefaultCombo("Container").setText(containerName);
    new OkButton().click();
}
Also used : OkButton(org.eclipse.reddeer.swt.impl.button.OkButton) DefaultCombo(org.eclipse.reddeer.swt.impl.combo.DefaultCombo) WithTextMatcher(org.eclipse.reddeer.core.matcher.WithTextMatcher) LabeledText(org.eclipse.reddeer.swt.impl.text.LabeledText) RadioButton(org.eclipse.reddeer.swt.impl.button.RadioButton) PushButton(org.eclipse.reddeer.swt.impl.button.PushButton)

Example 14 with DefaultCombo

use of org.eclipse.reddeer.swt.impl.combo.DefaultCombo in project jbosstools-openshift by jbosstools.

the class EditResourceLimitsTest method incrementLimits.

private void incrementLimits(int index, String defaultSuffix) {
    new ContextMenuItem(OpenShiftLabel.ContextMenu.EDIT_RESOURCE_LIMITS).select();
    new WaitUntil(new ShellIsAvailable(OpenShiftLabel.Shell.EDIT_RESOURCE_LIMITS));
    new DefaultShell(OpenShiftLabel.Shell.EDIT_RESOURCE_LIMITS).setFocus();
    Text text = new DefaultText(index);
    String value = text.getText();
    long val = 0L;
    try {
        val = Long.parseLong(value);
    } catch (NumberFormatException e) {
    }
    text.setText(Long.toString(++val));
    Combo combo = new DefaultCombo(index);
    value = combo.getSelection();
    if (StringUtils.isEmpty(value)) {
        combo.setSelection(defaultSuffix);
    }
    new WaitUntil(new ControlIsEnabled(new OkButton()));
    new OkButton().click();
}
Also used : ShellIsAvailable(org.eclipse.reddeer.swt.condition.ShellIsAvailable) ContextMenuItem(org.eclipse.reddeer.swt.impl.menu.ContextMenuItem) Text(org.eclipse.reddeer.swt.api.Text) DefaultText(org.eclipse.reddeer.swt.impl.text.DefaultText) DefaultCombo(org.eclipse.reddeer.swt.impl.combo.DefaultCombo) Combo(org.eclipse.reddeer.swt.api.Combo) DefaultText(org.eclipse.reddeer.swt.impl.text.DefaultText) OkButton(org.eclipse.reddeer.swt.impl.button.OkButton) DefaultCombo(org.eclipse.reddeer.swt.impl.combo.DefaultCombo) DefaultShell(org.eclipse.reddeer.swt.impl.shell.DefaultShell) ControlIsEnabled(org.eclipse.reddeer.swt.condition.ControlIsEnabled) WaitUntil(org.eclipse.reddeer.common.wait.WaitUntil)

Example 15 with DefaultCombo

use of org.eclipse.reddeer.swt.impl.combo.DefaultCombo in project jbosstools-openshift by jbosstools.

the class CreateApplicationFromTemplateTest method importTestsProject.

@BeforeClass
public static void importTestsProject() {
    new ExternalProjectImportWizardDialog().open();
    new DefaultCombo().setText(TESTS_PROJECT_LOCATION);
    new PushButton("Refresh").click();
    new WaitUntil(new ControlIsEnabled(new FinishButton()), TimePeriod.LONG);
    new FinishButton().click();
    new WaitWhile(new JobIsRunning(), TimePeriod.LONG);
    new WaitUntil(new ProjectExists(TESTS_PROJECT), TimePeriod.LONG);
}
Also used : DefaultCombo(org.eclipse.reddeer.swt.impl.combo.DefaultCombo) FinishButton(org.eclipse.reddeer.swt.impl.button.FinishButton) WaitWhile(org.eclipse.reddeer.common.wait.WaitWhile) ProjectExists(org.eclipse.reddeer.eclipse.condition.ProjectExists) ControlIsEnabled(org.eclipse.reddeer.swt.condition.ControlIsEnabled) JobIsRunning(org.eclipse.reddeer.workbench.core.condition.JobIsRunning) PushButton(org.eclipse.reddeer.swt.impl.button.PushButton) WaitUntil(org.eclipse.reddeer.common.wait.WaitUntil) ExternalProjectImportWizardDialog(org.eclipse.reddeer.eclipse.ui.wizards.datatransfer.ExternalProjectImportWizardDialog) BeforeClass(org.junit.BeforeClass)

Aggregations

DefaultCombo (org.eclipse.reddeer.swt.impl.combo.DefaultCombo)19 WaitUntil (org.eclipse.reddeer.common.wait.WaitUntil)8 WaitWhile (org.eclipse.reddeer.common.wait.WaitWhile)8 ShellIsAvailable (org.eclipse.reddeer.swt.condition.ShellIsAvailable)8 DefaultShell (org.eclipse.reddeer.swt.impl.shell.DefaultShell)8 ControlIsEnabled (org.eclipse.reddeer.swt.condition.ControlIsEnabled)7 FinishButton (org.eclipse.reddeer.swt.impl.button.FinishButton)7 Combo (org.eclipse.reddeer.swt.api.Combo)6 LabeledText (org.eclipse.reddeer.swt.impl.text.LabeledText)6 JobIsRunning (org.eclipse.reddeer.workbench.core.condition.JobIsRunning)6 PushButton (org.eclipse.reddeer.swt.impl.button.PushButton)5 ContextMenu (org.eclipse.reddeer.swt.impl.menu.ContextMenu)5 NextButton (org.eclipse.reddeer.swt.impl.button.NextButton)4 OkButton (org.eclipse.reddeer.swt.impl.button.OkButton)4 Test (org.junit.Test)4 Shell (org.eclipse.reddeer.swt.api.Shell)3 BackButton (org.eclipse.reddeer.swt.impl.button.BackButton)3 LabeledCombo (org.eclipse.reddeer.swt.impl.combo.LabeledCombo)3 DefaultGroup (org.eclipse.reddeer.swt.impl.group.DefaultGroup)3 WorkbenchShell (org.eclipse.reddeer.workbench.impl.shell.WorkbenchShell)3