JBoss Tools SVN: r41233 - in trunk/archives/tests/org.jboss.tools.archives.ui.bot.test/src/org/jboss/tools/archives/ui/bot/test: context and 1 other directory.
by jbosstools-commits@lists.jboss.org
Author: jjankovi
Date: 2012-05-22 05:12:04 -0400 (Tue, 22 May 2012)
New Revision: 41233
Added:
trunk/archives/tests/org.jboss.tools.archives.ui.bot.test/src/org/jboss/tools/archives/ui/bot/test/context/
trunk/archives/tests/org.jboss.tools.archives.ui.bot.test/src/org/jboss/tools/archives/ui/bot/test/context/ArchiveContextMenu.java
Log:
ContextMenu of all Project Archives options used in Project Archives view and Project Archives explorer within project
Added: trunk/archives/tests/org.jboss.tools.archives.ui.bot.test/src/org/jboss/tools/archives/ui/bot/test/context/ArchiveContextMenu.java
===================================================================
--- trunk/archives/tests/org.jboss.tools.archives.ui.bot.test/src/org/jboss/tools/archives/ui/bot/test/context/ArchiveContextMenu.java (rev 0)
+++ trunk/archives/tests/org.jboss.tools.archives.ui.bot.test/src/org/jboss/tools/archives/ui/bot/test/context/ArchiveContextMenu.java 2012-05-22 09:12:04 UTC (rev 41233)
@@ -0,0 +1,88 @@
+/*******************************************************************************
+ * Copyright (c) 2010-2012 Red Hat, Inc.
+ * Distributed under license by Red Hat, Inc. All rights reserved.
+ * This program is made available under the terms of the
+ * Eclipse Public License v1.0 which accompanies this distribution,
+ * and is available at http://www.eclipse.org/legal/epl-v10.html
+ *
+ * Contributors:
+ * Red Hat, Inc. - initial API and implementation
+ ******************************************************************************/
+package org.jboss.tools.archives.ui.bot.test.context;
+
+import org.eclipse.swtbot.swt.finder.widgets.SWTBotMenu;
+import org.eclipse.swtbot.swt.finder.widgets.SWTBotTree;
+import org.eclipse.swtbot.swt.finder.widgets.SWTBotTreeItem;
+import org.jboss.tools.archives.ui.bot.test.dialog.ArchivePublishSettingsDialog;
+import org.jboss.tools.archives.ui.bot.test.dialog.EditArchiveDialog;
+import org.jboss.tools.archives.ui.bot.test.dialog.NewJarDialog;
+import org.jboss.tools.ui.bot.ext.helper.ContextMenuHelper;
+
+/**
+ *
+ * @author jjankovi
+ *
+ */
+public class ArchiveContextMenu {
+
+ public NewJarDialog createNewJarArchive(SWTBotTree tree,
+ SWTBotTreeItem item) {
+ ContextMenuHelper.prepareTreeItemForContextMenu(tree, item);
+ SWTBotMenu menu = new SWTBotMenu(ContextMenuHelper.
+ getContextMenu(tree, "New Archive", false)).menu("JAR");
+ menu.click();
+ return new NewJarDialog();
+ }
+
+ public void buildProjectFull(SWTBotTree tree,
+ SWTBotTreeItem item) {
+ ContextMenuHelper.prepareTreeItemForContextMenu(tree, item);
+ SWTBotMenu menu = new SWTBotMenu(ContextMenuHelper.
+ getContextMenu(tree, "Build Project (Full)", false));
+ menu.click();
+ }
+
+ public void buildArchiveFull(SWTBotTree tree,
+ SWTBotTreeItem item) {
+ ContextMenuHelper.prepareTreeItemForContextMenu(tree, item);
+ SWTBotMenu menu = new SWTBotMenu(ContextMenuHelper.
+ getContextMenu(tree, "Build Archive (Full)", false));
+ menu.click();
+ }
+
+ public EditArchiveDialog editArchive(SWTBotTree tree,
+ SWTBotTreeItem item) {
+ ContextMenuHelper.prepareTreeItemForContextMenu(tree, item);
+ SWTBotMenu menu = new SWTBotMenu(ContextMenuHelper.
+ getContextMenu(tree, "Edit Archive", false));
+ menu.click();
+ return new EditArchiveDialog();
+ }
+
+ public void deleteArchive(SWTBotTree tree,
+ SWTBotTreeItem item) {
+ ContextMenuHelper.prepareTreeItemForContextMenu(tree, item);
+ SWTBotMenu menu = new SWTBotMenu(ContextMenuHelper.
+ getContextMenu(tree, "Delete Archive", false));
+ menu.click();
+ }
+
+ public ArchivePublishSettingsDialog publishToServer(SWTBotTree tree,
+ SWTBotTreeItem item) {
+ ContextMenuHelper.prepareTreeItemForContextMenu(tree, item);
+ SWTBotMenu menu = new SWTBotMenu(ContextMenuHelper.
+ getContextMenu(tree, "Publish To Server", false));
+ menu.click();
+ return new ArchivePublishSettingsDialog();
+ }
+
+ public ArchivePublishSettingsDialog editPublishSettings(SWTBotTree tree,
+ SWTBotTreeItem item) {
+ ContextMenuHelper.prepareTreeItemForContextMenu(tree, item);
+ SWTBotMenu menu = new SWTBotMenu(ContextMenuHelper.
+ getContextMenu(tree, "Edit publish settings...", false));
+ menu.click();
+ return new ArchivePublishSettingsDialog();
+ }
+
+}
12 years, 7 months
JBoss Tools SVN: r41232 - trunk/archives/tests/org.jboss.tools.archives.ui.bot.test/src/org/jboss/tools/archives/ui/bot/test.
by jbosstools-commits@lists.jboss.org
Author: jjankovi
Date: 2012-05-22 05:10:50 -0400 (Tue, 22 May 2012)
New Revision: 41232
Modified:
trunk/archives/tests/org.jboss.tools.archives.ui.bot.test/src/org/jboss/tools/archives/ui/bot/test/ArchivesAllBotTests.java
Log:
testsuite is now empty
Modified: trunk/archives/tests/org.jboss.tools.archives.ui.bot.test/src/org/jboss/tools/archives/ui/bot/test/ArchivesAllBotTests.java
===================================================================
--- trunk/archives/tests/org.jboss.tools.archives.ui.bot.test/src/org/jboss/tools/archives/ui/bot/test/ArchivesAllBotTests.java 2012-05-22 09:10:00 UTC (rev 41231)
+++ trunk/archives/tests/org.jboss.tools.archives.ui.bot.test/src/org/jboss/tools/archives/ui/bot/test/ArchivesAllBotTests.java 2012-05-22 09:10:50 UTC (rev 41232)
@@ -19,7 +19,8 @@
* @author Jaroslav Jankovic
*/
@RunWith(RequirementAwareSuite.class)
-@SuiteClasses({
+@SuiteClasses({
+
})
public class ArchivesAllBotTests {
12 years, 7 months
JBoss Tools SVN: r41231 - in trunk/archives/tests/org.jboss.tools.archives.ui.bot.test: properties and 1 other directory.
by jbosstools-commits@lists.jboss.org
Author: jjankovi
Date: 2012-05-22 05:10:00 -0400 (Tue, 22 May 2012)
New Revision: 41231
Added:
trunk/archives/tests/org.jboss.tools.archives.ui.bot.test/properties/
trunk/archives/tests/org.jboss.tools.archives.ui.bot.test/properties/swtbot.properties
Log:
swtbot.properties file added
Added: trunk/archives/tests/org.jboss.tools.archives.ui.bot.test/properties/swtbot.properties
===================================================================
--- trunk/archives/tests/org.jboss.tools.archives.ui.bot.test/properties/swtbot.properties (rev 0)
+++ trunk/archives/tests/org.jboss.tools.archives.ui.bot.test/properties/swtbot.properties 2012-05-22 09:10:00 UTC (rev 41231)
@@ -0,0 +1 @@
+SERVER=AS,7.1,default,target/requirements/jboss-as-7.1.1.Final
12 years, 7 months
JBoss Tools SVN: r41230 - trunk/archives/tests/org.jboss.tools.archives.ui.bot.test.
by jbosstools-commits@lists.jboss.org
Author: jjankovi
Date: 2012-05-22 05:09:40 -0400 (Tue, 22 May 2012)
New Revision: 41230
Added:
trunk/archives/tests/org.jboss.tools.archives.ui.bot.test/ArchivesAllBotTests.launch
Log:
eclipse launcher added
Added: trunk/archives/tests/org.jboss.tools.archives.ui.bot.test/ArchivesAllBotTests.launch
===================================================================
--- trunk/archives/tests/org.jboss.tools.archives.ui.bot.test/ArchivesAllBotTests.launch (rev 0)
+++ trunk/archives/tests/org.jboss.tools.archives.ui.bot.test/ArchivesAllBotTests.launch 2012-05-22 09:09:40 UTC (rev 41230)
@@ -0,0 +1,43 @@
+<?xml version="1.0" encoding="UTF-8" standalone="no"?>
+<launchConfiguration type="org.eclipse.swtbot.eclipse.ui.launcher.JunitLaunchConfig">
+<booleanAttribute key="append.args" value="true"/>
+<booleanAttribute key="askclear" value="false"/>
+<booleanAttribute key="automaticAdd" value="true"/>
+<booleanAttribute key="automaticValidate" value="false"/>
+<stringAttribute key="bootstrap" value=""/>
+<stringAttribute key="checked" value="[NONE]"/>
+<booleanAttribute key="clearConfig" value="true"/>
+<booleanAttribute key="clearws" value="true"/>
+<booleanAttribute key="clearwslog" value="false"/>
+<stringAttribute key="configLocation" value="${workspace_loc}/.metadata/.plugins/org.eclipse.pde.core/pde-junit"/>
+<booleanAttribute key="default" value="true"/>
+<booleanAttribute key="includeOptional" value="true"/>
+<stringAttribute key="location" value="${workspace_loc}/../junit-workspace"/>
+<listAttribute key="org.eclipse.debug.core.MAPPED_RESOURCE_PATHS">
+<listEntry value="/org.jboss.tools.archives.ui.bot.test/src/org/jboss/tools/archives/ui/bot/test/ArchivesAllBotTests.java"/>
+</listAttribute>
+<listAttribute key="org.eclipse.debug.core.MAPPED_RESOURCE_TYPES">
+<listEntry value="1"/>
+</listAttribute>
+<mapAttribute key="org.eclipse.debug.core.environmentVariables">
+<mapEntry key="DISPLAY" value=":1"/>
+</mapAttribute>
+<stringAttribute key="org.eclipse.jdt.junit.CONTAINER" value=""/>
+<booleanAttribute key="org.eclipse.jdt.junit.KEEPRUNNING_ATTR" value="false"/>
+<stringAttribute key="org.eclipse.jdt.junit.TESTNAME" value=""/>
+<stringAttribute key="org.eclipse.jdt.junit.TEST_KIND" value="org.eclipse.jdt.junit.loader.junit4"/>
+<stringAttribute key="org.eclipse.jdt.launching.MAIN_TYPE" value="org.jboss.tools.archives.ui.bot.test.ArchivesAllBotTests"/>
+<stringAttribute key="org.eclipse.jdt.launching.PROGRAM_ARGUMENTS" value="-os ${target.os} -ws ${target.ws} -arch ${target.arch} -nl ${target.nl} -consoleLog"/>
+<stringAttribute key="org.eclipse.jdt.launching.PROJECT_ATTR" value="org.jboss.tools.archives.ui.bot.test"/>
+<stringAttribute key="org.eclipse.jdt.launching.SOURCE_PATH_PROVIDER" value="org.eclipse.pde.ui.workbenchClasspathProvider"/>
+<stringAttribute key="org.eclipse.jdt.launching.VM_ARGUMENTS" value="-Dosgi.requiredJavaVersion=1.5 -XX:MaxPermSize=256m -Xms256m -Xmx1024m -Dswtbot.test.properties.file=${env_var:HOME}/swtbot.properties -Dusage_reporting_enabled=false"/>
+<stringAttribute key="pde.version" value="3.3"/>
+<stringAttribute key="product" value="org.eclipse.platform.ide"/>
+<booleanAttribute key="show_selected_only" value="false"/>
+<stringAttribute key="templateConfig" value="${target_home}/configuration/config.ini"/>
+<booleanAttribute key="tracing" value="false"/>
+<booleanAttribute key="useCustomFeatures" value="false"/>
+<booleanAttribute key="useDefaultConfig" value="true"/>
+<booleanAttribute key="useDefaultConfigArea" value="false"/>
+<booleanAttribute key="useProduct" value="true"/>
+</launchConfiguration>
12 years, 7 months
JBoss Tools SVN: r41228 - in trunk/openshift/plugins/org.jboss.tools.openshift.express.ui/src/org/jboss/tools/openshift/express/internal/ui: behaviour and 1 other directory.
by jbosstools-commits@lists.jboss.org
Author: rob.stryker(a)jboss.com
Date: 2012-05-22 02:53:14 -0400 (Tue, 22 May 2012)
New Revision: 41228
Modified:
trunk/openshift/plugins/org.jboss.tools.openshift.express.ui/src/org/jboss/tools/openshift/express/internal/ui/OpenshiftUIMessages.java
trunk/openshift/plugins/org.jboss.tools.openshift.express.ui/src/org/jboss/tools/openshift/express/internal/ui/OpenshiftUIMessages.properties
trunk/openshift/plugins/org.jboss.tools.openshift.express.ui/src/org/jboss/tools/openshift/express/internal/ui/behaviour/ExpressDetailsSection.java
Log:
JBIDE-11847 - fixing style and externalize some strings
Modified: trunk/openshift/plugins/org.jboss.tools.openshift.express.ui/src/org/jboss/tools/openshift/express/internal/ui/OpenshiftUIMessages.java
===================================================================
--- trunk/openshift/plugins/org.jboss.tools.openshift.express.ui/src/org/jboss/tools/openshift/express/internal/ui/OpenshiftUIMessages.java 2012-05-22 06:22:24 UTC (rev 41227)
+++ trunk/openshift/plugins/org.jboss.tools.openshift.express.ui/src/org/jboss/tools/openshift/express/internal/ui/OpenshiftUIMessages.java 2012-05-22 06:53:14 UTC (rev 41228)
@@ -21,7 +21,14 @@
}
public static String OpenshiftWizardSavePassword;
-
+ public static String EditorSectionAppNameLabel;
+ public static String EditorSectionDeployLocLabel;
+ public static String EditorSectionZipDestLabel;
+ public static String EditorSectionUserLabel;
+ public static String EditorSectionRemoteLabel;
+ public static String EditorSectionBrowseDestButton;
+ public static String EditorSectionProjectSettingsGroup;
+ public static String EditorSectionOverrideProjectSettings;
Modified: trunk/openshift/plugins/org.jboss.tools.openshift.express.ui/src/org/jboss/tools/openshift/express/internal/ui/OpenshiftUIMessages.properties
===================================================================
--- trunk/openshift/plugins/org.jboss.tools.openshift.express.ui/src/org/jboss/tools/openshift/express/internal/ui/OpenshiftUIMessages.properties 2012-05-22 06:22:24 UTC (rev 41227)
+++ trunk/openshift/plugins/org.jboss.tools.openshift.express.ui/src/org/jboss/tools/openshift/express/internal/ui/OpenshiftUIMessages.properties 2012-05-22 06:53:14 UTC (rev 41228)
@@ -1 +1,9 @@
-OpenshiftWizardSavePassword=Save password (could trigger secure storage login)
\ No newline at end of file
+OpenshiftWizardSavePassword=Save password (could trigger secure storage login)
+EditorSectionAppNameLabel=Application Name:
+EditorSectionDeployLocLabel=Deploy Project:
+EditorSectionZipDestLabel=Output Directory:
+EditorSectionUserLabel=Username:
+EditorSectionRemoteLabel=Remote:
+EditorSectionBrowseDestButton=Browse...
+EditorSectionProjectSettingsGroup=Project Settings:
+EditorSectionOverrideProjectSettings=Override Project Settings
Modified: trunk/openshift/plugins/org.jboss.tools.openshift.express.ui/src/org/jboss/tools/openshift/express/internal/ui/behaviour/ExpressDetailsSection.java
===================================================================
--- trunk/openshift/plugins/org.jboss.tools.openshift.express.ui/src/org/jboss/tools/openshift/express/internal/ui/behaviour/ExpressDetailsSection.java 2012-05-22 06:22:24 UTC (rev 41227)
+++ trunk/openshift/plugins/org.jboss.tools.openshift.express.ui/src/org/jboss/tools/openshift/express/internal/ui/behaviour/ExpressDetailsSection.java 2012-05-22 06:53:14 UTC (rev 41228)
@@ -16,9 +16,6 @@
import org.eclipse.core.resources.IProject;
import org.eclipse.core.resources.IResource;
import org.eclipse.core.resources.ResourcesPlugin;
-import org.eclipse.core.runtime.IAdaptable;
-import org.eclipse.core.runtime.IProgressMonitor;
-import org.eclipse.core.runtime.IStatus;
import org.eclipse.core.runtime.Path;
import org.eclipse.jface.layout.GridDataFactory;
import org.eclipse.jface.viewers.ILabelProvider;
@@ -57,6 +54,7 @@
import org.jboss.ide.eclipse.as.ui.editor.ServerWorkingCopyPropertyComboCommand;
import org.jboss.ide.eclipse.as.ui.editor.ServerWorkingCopyPropertyCommand;
import org.jboss.tools.openshift.express.internal.core.behaviour.ExpressServerUtils;
+import org.jboss.tools.openshift.express.internal.ui.OpenshiftUIMessages;
public class ExpressDetailsSection extends ServerEditorSection {
private IEditorInput input;
@@ -79,9 +77,9 @@
Section section = toolkit.createSection(parent, ExpandableComposite.TWISTIE|ExpandableComposite.EXPANDED|ExpandableComposite.TITLE_BAR);
section.setText("Openshift Server");
section.setLayoutData(new GridData(GridData.FILL_HORIZONTAL | GridData.VERTICAL_ALIGN_FILL | GridData.GRAB_HORIZONTAL| GridData.GRAB_VERTICAL));
- Composite c = new Composite(section, SWT.NONE);
+ Composite c = toolkit.createComposite(section, SWT.NONE);
c.setLayout(new GridLayout(2,true));
- createWidgets(c);
+ createWidgets(c, toolkit);
toolkit.paintBordersFor(c);
toolkit.adapt(c);
section.setClient(c);
@@ -131,14 +129,14 @@
}
protected Composite createComposite(Section section) {
- createWidgets(section);
+ createWidgets(section, new FormToolkit(section.getDisplay()));
return section;
}
- private void createWidgets(Composite composite) {
+ private void createWidgets(Composite composite, FormToolkit toolkit) {
composite.setLayout(new GridLayout(2, false));
-
- Label deployLocationLabel = new Label(composite, SWT.NONE);
+
+ Label deployLocationLabel = toolkit.createLabel(composite, OpenshiftUIMessages.EditorSectionDeployLocLabel, SWT.NONE);
deployProjectCombo = new Combo(composite, SWT.SINGLE | SWT.BORDER | SWT.READ_ONLY);
GridDataFactory.fillDefaults().align(SWT.FILL, SWT.FILL).grab(true, false).applyTo(deployProjectCombo);
@@ -146,45 +144,35 @@
projectSettingGroup = new Group(composite, SWT.NONE);
GridDataFactory.fillDefaults().align(SWT.FILL, SWT.FILL).grab(true, false).span(2, 1).applyTo(projectSettingGroup);
projectSettingGroup.setLayout(new GridLayout(2, false));
+ projectSettingGroup.setText(OpenshiftUIMessages.EditorSectionProjectSettingsGroup);
- overrideProjectSettings = new Button(projectSettingGroup, SWT.CHECK);
+ overrideProjectSettings = toolkit.createButton(projectSettingGroup, OpenshiftUIMessages.EditorSectionOverrideProjectSettings, SWT.CHECK);
GridDataFactory.fillDefaults().align(SWT.FILL, SWT.FILL).grab(true, false).span(2, 1).applyTo(overrideProjectSettings);
- Label userLabel = new Label(projectSettingGroup, SWT.NONE);
+ Label userLabel = toolkit.createLabel(projectSettingGroup, OpenshiftUIMessages.EditorSectionUserLabel, SWT.NONE);
GridDataFactory.fillDefaults().align(SWT.LEFT, SWT.CENTER).applyTo(userLabel);
- userText = new Text(projectSettingGroup, SWT.SINGLE | SWT.BORDER);
+ userText = toolkit.createText(projectSettingGroup, "", SWT.SINGLE | SWT.BORDER);
GridDataFactory.fillDefaults().align(SWT.FILL, SWT.FILL).grab(true, false).applyTo(userText);
- Label appNameLabel = new Label(projectSettingGroup, SWT.NONE);
+
+ Label appNameLabel = toolkit.createLabel(projectSettingGroup, OpenshiftUIMessages.EditorSectionAppNameLabel, SWT.NONE);
GridDataFactory.fillDefaults()
.align(SWT.LEFT, SWT.CENTER).applyTo(appNameLabel);
- appNameText = new Text(projectSettingGroup, SWT.SINGLE | SWT.BORDER);
+ appNameText = toolkit.createText(projectSettingGroup, "", SWT.SINGLE | SWT.BORDER);
GridDataFactory.fillDefaults().align(SWT.FILL, SWT.FILL).grab(true, false).applyTo(appNameText);
- Label zipDestLabel = new Label(projectSettingGroup, SWT.NONE);
- Composite zipDestComposite = new Composite(projectSettingGroup, SWT.NONE);
+ Label zipDestLabel = toolkit.createLabel(projectSettingGroup, OpenshiftUIMessages.EditorSectionZipDestLabel, SWT.NONE);
+ Composite zipDestComposite = toolkit.createComposite(projectSettingGroup, SWT.NONE);
GridDataFactory.fillDefaults().align(SWT.FILL, SWT.FILL).grab(true, false).applyTo(zipDestComposite);
zipDestComposite.setLayout(new FormLayout());
- browseDestButton = new Button(zipDestComposite, SWT.PUSH);
+ browseDestButton = toolkit.createButton(zipDestComposite, OpenshiftUIMessages.EditorSectionBrowseDestButton, SWT.PUSH);
browseDestButton.setLayoutData(UIUtil.createFormData2(0,5,100,-5,null,0,100,0));
- deployFolderText = new Text(zipDestComposite, SWT.SINGLE | SWT.BORDER);
+ deployFolderText = toolkit.createText(zipDestComposite, "", SWT.SINGLE | SWT.BORDER);
deployFolderText.setLayoutData(UIUtil.createFormData2(0,5,100,-5,0,0,browseDestButton,-5));
- Label remoteLabel = new Label(projectSettingGroup, SWT.NONE);
+ Label remoteLabel = toolkit.createLabel(projectSettingGroup, OpenshiftUIMessages.EditorSectionRemoteLabel, SWT.NONE);
GridDataFactory.fillDefaults().align(SWT.LEFT, SWT.CENTER).applyTo(remoteLabel);
- remoteText = new Text(projectSettingGroup, SWT.SINGLE | SWT.BORDER);
+ remoteText = toolkit.createText(projectSettingGroup, "", SWT.SINGLE | SWT.BORDER);
GridDataFactory.fillDefaults().align(SWT.FILL, SWT.FILL).grab(true, false).applyTo(remoteText);
-
-
-
- // Text
- appNameLabel.setText("Application Name: ");
- deployLocationLabel.setText("Deploy Project: " );
- zipDestLabel.setText("Output Directory: ");
- userLabel.setText("Username: ");
- remoteLabel.setText("Remote: ");
- browseDestButton.setText("Browse...");
- projectSettingGroup.setText("Project Settings:");
- overrideProjectSettings.setText("Override Project Settings");
}
ModifyListener remoteModifyListener, deployDestinationModifyListener, deployProjectListener;
12 years, 7 months
JBoss Tools SVN: r41227 - in trunk/as/plugins/org.jboss.ide.eclipse.as.core/jbosscore/org/jboss/ide/eclipse/as/core: server/internal/v7 and 1 other directory.
by jbosstools-commits@lists.jboss.org
Author: rob.stryker(a)jboss.com
Date: 2012-05-22 02:22:24 -0400 (Tue, 22 May 2012)
New Revision: 41227
Modified:
trunk/as/plugins/org.jboss.ide.eclipse.as.core/jbosscore/org/jboss/ide/eclipse/as/core/resolvers/ConfigNameResolver.java
trunk/as/plugins/org.jboss.ide.eclipse.as.core/jbosscore/org/jboss/ide/eclipse/as/core/server/internal/v7/JBoss7Server.java
Log:
JBIDE-11887
Modified: trunk/as/plugins/org.jboss.ide.eclipse.as.core/jbosscore/org/jboss/ide/eclipse/as/core/resolvers/ConfigNameResolver.java
===================================================================
--- trunk/as/plugins/org.jboss.ide.eclipse.as.core/jbosscore/org/jboss/ide/eclipse/as/core/resolvers/ConfigNameResolver.java 2012-05-22 00:46:30 UTC (rev 41226)
+++ trunk/as/plugins/org.jboss.ide.eclipse.as.core/jbosscore/org/jboss/ide/eclipse/as/core/resolvers/ConfigNameResolver.java 2012-05-22 06:22:24 UTC (rev 41227)
@@ -142,8 +142,9 @@
IServer[] servers = ServerCore.getServers();
for( int i = 0; i < servers.length; i++ ) {
if( servers[i].getName().equals(serverOrRuntimeName)) {
- return (IJBossServerRuntime) servers[i].getRuntime()
- .loadAdapter(IJBossServerRuntime.class, new NullProgressMonitor());
+ if( servers[i].getRuntime() != null )
+ return (IJBossServerRuntime) servers[i].getRuntime()
+ .loadAdapter(IJBossServerRuntime.class, new NullProgressMonitor());
}
}
IRuntime[] runtimes = ServerCore.getRuntimes();
Modified: trunk/as/plugins/org.jboss.ide.eclipse.as.core/jbosscore/org/jboss/ide/eclipse/as/core/server/internal/v7/JBoss7Server.java
===================================================================
--- trunk/as/plugins/org.jboss.ide.eclipse.as.core/jbosscore/org/jboss/ide/eclipse/as/core/server/internal/v7/JBoss7Server.java 2012-05-22 00:46:30 UTC (rev 41226)
+++ trunk/as/plugins/org.jboss.ide.eclipse.as.core/jbosscore/org/jboss/ide/eclipse/as/core/server/internal/v7/JBoss7Server.java 2012-05-22 06:22:24 UTC (rev 41227)
@@ -68,6 +68,8 @@
if( type.equals(DEPLOY_SERVER) ) {
// TODO make sure this is correct?! Upstream APIs have this wrong for as7
IRuntime rt = getServer().getRuntime();
+ if( rt == null )
+ return null;
IPath p = rt.getLocation().append(AS7_STANDALONE).append(AS7_DEPLOYMENTS);
return ServerUtil.makeGlobal(rt, p).toString();
}
12 years, 7 months
JBoss Tools SVN: r41226 - in trunk/esb/tests/org.jboss.tools.esb.ui.bot.test: src/org/jboss/tools/esb/ui/bot/tests/examples and 1 other directory.
by jbosstools-commits@lists.jboss.org
Author: ldimaggio
Date: 2012-05-21 20:46:30 -0400 (Mon, 21 May 2012)
New Revision: 41226
Modified:
trunk/esb/tests/org.jboss.tools.esb.ui.bot.test/pom.xml
trunk/esb/tests/org.jboss.tools.esb.ui.bot.test/src/org/jboss/tools/esb/ui/bot/tests/examples/ESBExampleTest.java
Log:
Extended timeout to 2 hours in pom.xml, refactored some code in code in ESBExampleTest.java - console switching
Modified: trunk/esb/tests/org.jboss.tools.esb.ui.bot.test/pom.xml
===================================================================
--- trunk/esb/tests/org.jboss.tools.esb.ui.bot.test/pom.xml 2012-05-21 21:24:37 UTC (rev 41225)
+++ trunk/esb/tests/org.jboss.tools.esb.ui.bot.test/pom.xml 2012-05-22 00:46:30 UTC (rev 41226)
@@ -29,7 +29,7 @@
<skip>${swtbot.test.skip}</skip>
<testSuite>org.jboss.tools.esb.ui.bot.test</testSuite>
<testClass>org.jboss.tools.esb.ui.bot.tests.ESBAllBotTests</testClass>
- <forkedProcessTimeoutInSeconds>3600</forkedProcessTimeoutInSeconds>
+ <forkedProcessTimeoutInSeconds>7200</forkedProcessTimeoutInSeconds>
</configuration>
</plugin>
</plugins>
Modified: trunk/esb/tests/org.jboss.tools.esb.ui.bot.test/src/org/jboss/tools/esb/ui/bot/tests/examples/ESBExampleTest.java
===================================================================
--- trunk/esb/tests/org.jboss.tools.esb.ui.bot.test/src/org/jboss/tools/esb/ui/bot/tests/examples/ESBExampleTest.java 2012-05-21 21:24:37 UTC (rev 41225)
+++ trunk/esb/tests/org.jboss.tools.esb.ui.bot.test/src/org/jboss/tools/esb/ui/bot/tests/examples/ESBExampleTest.java 2012-05-22 00:46:30 UTC (rev 41226)
@@ -113,17 +113,19 @@
}
//console.switchConsole(configuredState.getServer().name);
- //String text2 = console.getConsoleText(TIME_5S, TIME_20S, false);
- String text2 = console.getConsoleText(TIME_5S, TIME_30S, false); /* https://issues.jboss.org/browse/JBQA-5838 - ldimaggi */
- log.info("text2 = " + text2);
- //console.clearConsole();
-
- if (text2.length() == 0) {
- return null;
- }
- else {
- return text2;
- }
+// //String text2 = console.getConsoleText(TIME_5S, TIME_20S, false);
+// String text2 = console.getConsoleText(TIME_5S, TIME_30S, false); /* https://issues.jboss.org/browse/JBQA-5838 - ldimaggi */
+// log.info("text2 = " + text2);
+// //console.clearConsole();
+//
+// if (text2.length() == 0) {
+// return null;
+// }
+// else {
+// return text2;
+// }
+ String returnString = consoleWaiting();
+ return returnString;
}
@@ -157,6 +159,38 @@
// }
// return text2.substring(text.length());
+// // New - the consoles fail to switch....sometimes
+// boolean consoleSwitched = false;
+// int switchLimit = 30;
+// int switchCounter = 0;
+// consoleSwitched = console.switchConsole(configuredState.getServer().name);
+// while (!consoleSwitched) {
+// consoleSwitched = console.switchConsole(configuredState.getServer().name);
+// bot.sleep(Timing.time10S());
+// log.error("Console did not switch - retrying.");
+// if (switchCounter++ > switchLimit) {
+// break;
+// }
+// }
+// //console.switchConsole(configuredState.getServer().name);
+//
+// //String text2 = console.getConsoleText(TIME_5S, TIME_20S, false);
+// String text2 = console.getConsoleText(TIME_5S, TIME_30S, false); /* https://issues.jboss.org/browse/JBQA-5838 - ldimaggi */
+// log.info("text2 = " + text2);
+// //console.clearConsole();
+//
+// if (text2.length() == 0) {
+// return null;
+// }
+// else {
+// return text2;
+// }
+ String returnString = consoleWaiting();
+ return returnString;
+ }
+
+
+ protected String consoleWaiting () {
// New - the consoles fail to switch....sometimes
boolean consoleSwitched = false;
int switchLimit = 30;
@@ -171,19 +205,19 @@
}
}
//console.switchConsole(configuredState.getServer().name);
-
+
//String text2 = console.getConsoleText(TIME_5S, TIME_20S, false);
String text2 = console.getConsoleText(TIME_5S, TIME_30S, false); /* https://issues.jboss.org/browse/JBQA-5838 - ldimaggi */
log.info("text2 = " + text2);
//console.clearConsole();
-
+
if (text2.length() == 0) {
return null;
}
else {
return text2;
}
- }
+ }
12 years, 7 months
JBoss Tools SVN: r41224 - in trunk/openshift/plugins: org.jboss.tools.openshift.express.ui/src/org/jboss/tools/openshift/express/internal/ui/action and 1 other directories.
by jbosstools-commits@lists.jboss.org
Author: xcoulon
Date: 2012-05-21 17:23:55 -0400 (Mon, 21 May 2012)
New Revision: 41224
Modified:
trunk/openshift/plugins/org.jboss.tools.openshift.express.client/openshift-java-client-2.0.0-SNAPSHOT.jar
trunk/openshift/plugins/org.jboss.tools.openshift.express.ui/src/org/jboss/tools/openshift/express/internal/ui/action/CreateApplicationAction.java
trunk/openshift/plugins/org.jboss.tools.openshift.express.ui/src/org/jboss/tools/openshift/express/internal/ui/action/DeleteDomainAction.java
trunk/openshift/plugins/org.jboss.tools.openshift.express.ui/src/org/jboss/tools/openshift/express/internal/ui/wizard/ApplicationConfigurationWizardPage.java
Log:
Fixed - JBIDE-11890
OpenShift Explorer: NPE when launching "New OpenShift Application"
Modified: trunk/openshift/plugins/org.jboss.tools.openshift.express.client/openshift-java-client-2.0.0-SNAPSHOT.jar
===================================================================
(Binary files differ)
Modified: trunk/openshift/plugins/org.jboss.tools.openshift.express.ui/src/org/jboss/tools/openshift/express/internal/ui/action/CreateApplicationAction.java
===================================================================
--- trunk/openshift/plugins/org.jboss.tools.openshift.express.ui/src/org/jboss/tools/openshift/express/internal/ui/action/CreateApplicationAction.java 2012-05-21 20:09:02 UTC (rev 41223)
+++ trunk/openshift/plugins/org.jboss.tools.openshift.express.ui/src/org/jboss/tools/openshift/express/internal/ui/action/CreateApplicationAction.java 2012-05-21 21:23:55 UTC (rev 41224)
@@ -56,6 +56,7 @@
}
}
+ /**
@Override
public void selectionChanged(SelectionChangedEvent event) {
super.selectionChanged(event);
@@ -68,9 +69,7 @@
enableWhenDomainExists();
}
- /**
* Enables the current action if the selected User has a default domain. Otherwise, the action is disabled.
- */
private void enableWhenDomainExists() {
if (selection != null && selection instanceof ITreeSelection) {
Object sel = ((ITreeSelection) selection).getFirstElement();
@@ -87,6 +86,7 @@
}
}
}
+ */
}
Modified: trunk/openshift/plugins/org.jboss.tools.openshift.express.ui/src/org/jboss/tools/openshift/express/internal/ui/action/DeleteDomainAction.java
===================================================================
--- trunk/openshift/plugins/org.jboss.tools.openshift.express.ui/src/org/jboss/tools/openshift/express/internal/ui/action/DeleteDomainAction.java 2012-05-21 20:09:02 UTC (rev 41223)
+++ trunk/openshift/plugins/org.jboss.tools.openshift.express.ui/src/org/jboss/tools/openshift/express/internal/ui/action/DeleteDomainAction.java 2012-05-21 21:23:55 UTC (rev 41224)
@@ -16,8 +16,8 @@
import org.eclipse.core.runtime.IStatus;
import org.eclipse.core.runtime.Status;
import org.eclipse.core.runtime.jobs.Job;
-import org.eclipse.jface.dialogs.ErrorDialog;
import org.eclipse.jface.dialogs.MessageDialog;
+import org.eclipse.jface.viewers.IStructuredSelection;
import org.eclipse.jface.viewers.ITreeSelection;
import org.eclipse.osgi.util.NLS;
import org.eclipse.swt.widgets.Display;
@@ -40,7 +40,7 @@
.getImageDescriptor(ISharedImages.IMG_ETOOL_DELETE));
}
- /*@Override
+ @Override
public void validate() {
boolean enable = false;
if (selection instanceof ITreeSelection
@@ -65,7 +65,7 @@
}
}
setEnabled(enable);
- }*/
+ }
@Override
public void run() {
Modified: trunk/openshift/plugins/org.jboss.tools.openshift.express.ui/src/org/jboss/tools/openshift/express/internal/ui/wizard/ApplicationConfigurationWizardPage.java
===================================================================
--- trunk/openshift/plugins/org.jboss.tools.openshift.express.ui/src/org/jboss/tools/openshift/express/internal/ui/wizard/ApplicationConfigurationWizardPage.java 2012-05-21 20:09:02 UTC (rev 41223)
+++ trunk/openshift/plugins/org.jboss.tools.openshift.express.ui/src/org/jboss/tools/openshift/express/internal/ui/wizard/ApplicationConfigurationWizardPage.java 2012-05-21 21:23:55 UTC (rev 41224)
@@ -627,27 +627,27 @@
@Override
protected void onPageActivated(final DataBindingContext dbc) {
- // This is needed for some strange freezing issues when
- // launching the wizard from the console view. The UI seems to freeze
- new Thread() {
- public void run() {
- Display.getDefault().asyncExec(new Runnable() {
- public void run() {
- loadOpenshiftResources(dbc);
- enableApplicationWidgets(pageModel.isUseExistingApplication());
- createExistingAppNameContentAssist();
- // this is needed because of weird issues with UI not
- // reacting to model changes while wizard runnable is
- // run. We force another update
- dbc.updateModels();
- // sort
- String[] items = newAppCartridgeCombo.getItems();
- Arrays.sort(items);
- newAppCartridgeCombo.setItems(items);
- }
- });
- }
- }.start();
+ if(checkForDomainExistance()) {
+ new Thread() {
+ public void run() {
+ Display.getDefault().asyncExec(new Runnable() {
+ public void run() {
+ loadOpenshiftResources(dbc);
+ enableApplicationWidgets(pageModel.isUseExistingApplication());
+ createExistingAppNameContentAssist();
+ // this is needed because of weird issues with UI not
+ // reacting to model changes while wizard runnable is
+ // run. We force another update
+ dbc.updateModels();
+ // sort
+ String[] items = newAppCartridgeCombo.getItems();
+ Arrays.sort(items);
+ newAppCartridgeCombo.setItems(items);
+ }
+ });
+ }
+ }.start();
+ }
}
@Override
@@ -655,6 +655,14 @@
if (direction == Direction.BACKWARDS) {
return;
}
+ //event.doit = checkForDomainExistance();
+ }
+
+ /**
+ * Checks that the user has a domain, opens the creation dialog in case he hasn't, closes the wizard if the user
+ * does not create a domain (required for any application creation). Otherwise, returns true.
+ */
+ private boolean checkForDomainExistance() {
try {
final UserDelegate user = this.pageModel.getUser();
if (user != null && !user.hasDomain()) {
@@ -666,16 +674,19 @@
if (result != Dialog.OK) {
final IWizardContainer container = getWizard().getContainer();
if (container instanceof WizardDialog) {
- event.doit = false;
((WizardDialog) container).close();
+ return false;
}
}
}
} catch (OpenShiftException e) {
Logger.error("Failed to refresh OpenShift account info", e);
+ return false;
} catch (SocketTimeoutException e) {
Logger.error("Failed to refresh OpenShift account info", e);
+ return false;
}
+ return true;
}
protected void loadOpenshiftResources(final DataBindingContext dbc) {
12 years, 7 months