Skip to content

Commit

Permalink
JBIDE-27821: reworked "addEnvironment" due to
Browse files Browse the repository at this point in the history
eclipse-archived/reddeer#2120

Signed-off-by: Oleksii Korniienko <[email protected]>
  • Loading branch information
olkornii committed May 31, 2021
1 parent ba4c7be commit 0ebee11
Showing 1 changed file with 4 additions and 10 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -13,16 +13,12 @@
import org.eclipse.reddeer.common.wait.TimePeriod;
import org.eclipse.reddeer.common.wait.WaitUntil;
import org.eclipse.reddeer.eclipse.condition.ConsoleHasText;
import org.eclipse.reddeer.eclipse.debug.ui.launchConfigurations.EnvironmentTab;
import org.eclipse.reddeer.eclipse.debug.ui.launchConfigurations.RunConfigurationsDialog;
import org.eclipse.reddeer.eclipse.ui.console.ConsoleView;
import org.eclipse.reddeer.swt.impl.button.OkButton;
import org.eclipse.reddeer.swt.impl.button.PushButton;
import org.eclipse.reddeer.swt.impl.ctab.DefaultCTabItem;
import org.eclipse.reddeer.swt.impl.shell.DefaultShell;
import org.eclipse.reddeer.swt.impl.text.LabeledText;
import org.jboss.tools.quarkus.integration.tests.launch.configuration.AbstractLaunchConfigurationTest;
import org.jboss.tools.quarkus.reddeer.common.QuarkusLabels.Shell;
import org.jboss.tools.quarkus.reddeer.common.QuarkusLabels.TextLabels;
import org.jboss.tools.quarkus.reddeer.ui.launch.QuarkusLaunchConfigurationTabGroup;

/**
Expand All @@ -49,11 +45,9 @@ public void addEnvironment(String projectName, RunConfigurationsDialog runDialog
QuarkusLaunchConfigurationTabGroup launchConfiguration) {
runDialog.open();
runDialog.select(launchConfiguration, projectName);
new DefaultCTabItem("Environment").activate();
new PushButton("Add...").click();
new LabeledText(TextLabels.NAME).setText(ENVIRONMENT_NAME);
new LabeledText(TextLabels.VALUE).setText("true");
new OkButton().click();
EnvironmentTab envTab = new EnvironmentTab();
envTab.activate();
envTab.add(ENVIRONMENT_NAME, "true");
new DefaultShell(Shell.RUN_CONFIGURATION).setFocus();
runDialog.close(true);
}
Expand Down

0 comments on commit 0ebee11

Please sign in to comment.