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 <olkornii@redhat.com>
  • Loading branch information
olkornii committed Jun 7, 2021
1 parent 70d0149 commit 38c5f0d
Showing 1 changed file with 4 additions and 10 deletions.
Original file line number Diff line number Diff line change
@@ -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;

/**
@@ -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);
}

0 comments on commit 38c5f0d

Please sign in to comment.