use of org.eclipse.reddeer.swt.impl.button.FinishButton in project linuxtools by eclipse.
the class EditDockerFileTest method testEditDockerFile.
@Test
public void testEditDockerFile() {
getConnection();
DockerImagesTab imageTab = openDockerImagesTab();
try {
String dockerFilePath = new File(EDIT_DOCKERFILE_FOLDER).getCanonicalPath();
getConnection();
imageTab.activate();
new DefaultToolItem("Build Image").click();
new WaitUntil(new ShellIsAvailable("Build a Docker Image"));
new LabeledText("Image Name:").setText(IMAGE_NAME);
new LabeledText("Directory:").setText(dockerFilePath);
new PushButton("Edit Dockerfile").click();
new WaitUntil(new ShellIsAvailable("Dockerfile Editor"), TimePeriod.LONG);
DefaultStyledText defaultStyledText = new DefaultStyledText();
String editorText = defaultStyledText.getText();
assertTrue("Editor is empty!", StringUtils.isNotEmpty(editorText));
defaultStyledText.setText(BUILD_IMAGE);
CTabFolder tabFolder = new DefaultCTabFolder();
CTabItem tabItem = tabFolder.getSelection();
KeyboardFactory.getKeyboard().invokeKeyCombination(SWT.CTRL, 'S');
tabItem.close();
new DefaultShell("Build a Docker Image").setFocus();
new FinishButton().click();
new WaitWhile(new JobIsRunning(), TimePeriod.VERY_LONG);
} catch (IOException ex) {
fail("Resource file not found!");
}
}
use of org.eclipse.reddeer.swt.impl.button.FinishButton in project linuxtools by eclipse.
the class ImageRunNetworkPage method finish.
public void finish() {
if (new FinishButton().isEnabled()) {
new FinishButton().click();
new WaitWhile(new JobIsRunning(), TimePeriod.VERY_LONG);
} else {
throw new RuntimeException("Image cannot be run! (Duplicate name?)");
}
}
use of org.eclipse.reddeer.swt.impl.button.FinishButton in project linuxtools by eclipse.
the class ImageRunSelectionPage method finish.
public void finish() {
if (new FinishButton().isEnabled()) {
new FinishButton().click();
new WaitWhile(new JobIsRunning(), TimePeriod.VERY_LONG);
} else {
throw new RuntimeException("Image cannot be run! (Duplicate name?)");
}
}
use of org.eclipse.reddeer.swt.impl.button.FinishButton in project linuxtools by eclipse.
the class ImageSearchPage method finish.
public void finish() {
new FinishButton().click();
new WaitWhile(new JobIsRunning(), TimePeriod.VERY_LONG);
}
use of org.eclipse.reddeer.swt.impl.button.FinishButton in project linuxtools by eclipse.
the class ImageTagSelectionPage method finish.
public void finish() {
new FinishButton().click();
new WaitWhile(new JobIsRunning(), TimePeriod.VERY_LONG);
}
Aggregations