JBoss Tools SVN: r27952 - trunk/tests/plugins/org.jboss.tools.tests/src/org/jboss/tools/test/util.
by jbosstools-commits@lists.jboss.org
Author: dgolovin
Date: 2011-01-06 14:00:44 -0500 (Thu, 06 Jan 2011)
New Revision: 27952
Modified:
trunk/tests/plugins/org.jboss.tools.tests/src/org/jboss/tools/test/util/Debug.java
Log:
https://issues.jboss.org/browse/JBIDE-8047 suppress "[Fatal Error] :1:1: Premature end of file." from logged AS test output
fix to remove output from ResourcesUtils class
Modified: trunk/tests/plugins/org.jboss.tools.tests/src/org/jboss/tools/test/util/Debug.java
===================================================================
--- trunk/tests/plugins/org.jboss.tools.tests/src/org/jboss/tools/test/util/Debug.java 2011-01-06 17:54:56 UTC (rev 27951)
+++ trunk/tests/plugins/org.jboss.tools.tests/src/org/jboss/tools/test/util/Debug.java 2011-01-06 19:00:44 UTC (rev 27952)
@@ -8,7 +8,7 @@
public static final boolean DEBUG_IMPORT_OPERATION;
static {
- DEBUG_IMPORT_OPERATION = true; //getDebugOption("/debug/importProject");
+ DEBUG_IMPORT_OPERATION = getDebugOption("/debug/importProject");
}
private static boolean getDebugOption(String option) {
13 years, 5 months
JBoss Tools SVN: r27951 - trunk/build.
by jbosstools-commits@lists.jboss.org
Author: nickboldt
Date: 2011-01-06 12:54:56 -0500 (Thu, 06 Jan 2011)
New Revision: 27951
Modified:
trunk/build/publish.sh
Log:
https://issues.jboss.org/browse/JBIDE-8066
Modified: trunk/build/publish.sh
===================================================================
--- trunk/build/publish.sh 2011-01-06 17:38:46 UTC (rev 27950)
+++ trunk/build/publish.sh 2011-01-06 17:54:56 UTC (rev 27951)
@@ -141,18 +141,32 @@
mkdir -p ${STAGINGDIR}/all
zip ${STAGINGDIR}/all/${SRCSNAME} -q -r * -x documentation\* -x download.jboss.org\* -x requirements\* \
-x workingset\* -x labs\* -x build\* -x \*test\* -x \*target\* -x \*.class -x \*.svn\* -x \*classes\* -x \*bin\* -x \*.zip \
- -x \*docs\* -x \*reference\* -x \*releng\*
+ -x \*docs\* -x \*reference\* -x \*releng\* -x \*.git\*
popd
# collect component zips from upstream aggregated build jobs
if [[ ${JOB_NAME/.aggregate} != ${JOB_NAME} ]] && [[ -d ${WORKSPACE}/sources/aggregate/site/zips ]]; then
mkdir -p ${STAGINGDIR}/components
- for z in $(find ${WORKSPACE}/sources/aggregate/site/zips -name "*Update*.zip") $(find ${WORKSPACE}/sources/aggregate/site/zips -name "*Sources*.zip"); do
+ for z in $(find ${WORKSPACE}/sources/aggregate/site/zips -name "*Update*.zip"); do
# generate MD5 sum for zip (file contains only the hash, not the hash + filename)
- for m in $(md5sum ${z}); do if [[ $m != ${z} ]]; then echo $m > ${z}.MD5; fi; done
-
+ for m in $(md5sum ${z}); do if [[ $m != ${z} ]]; then echo $m > ${z}.MD5; fi; done
mv $z ${z}.MD5 ${STAGINGDIR}/components
done
+
+ # unpack component source zips
+ for z in $(find ${WORKSPACE}/sources/aggregate/site/zips -name "*Sources*.zip"); do
+ unzip -q -d ${STAGINGDIR}/all/sources $z
+ done
+ # add component sources into sources zip
+ pushd ${STAGINGDIR}/all/sources
+ zip ${STAGINGDIR}/all/${SRCSNAME} -q -r * -x documentation\* -x download.jboss.org\* -x requirements\* \
+ -x workingset\* -x labs\* -x build\* -x \*test\* -x \*target\* -x \*.class -x \*.svn\* -x \*classes\* -x \*bin\* -x \*.zip \
+ -x \*docs\* -x \*reference\* -x \*releng\* -x \*.git\*
+ popd
+ rm -fr ${STAGINGDIR}/all/sources
+
+ z=${STAGINGDIR}/all/${SRCSNAME}
+ for m in $(md5sum ${z}); do if [[ $m != ${z} ]]; then echo $m > ${z}.MD5; fi; done
fi
# generate list of zips in this job
13 years, 5 months
JBoss Tools SVN: r27950 - trunk/seam/plugins/org.jboss.tools.seam.core/src/org/jboss/tools/seam/internal/core/project/facet.
by jbosstools-commits@lists.jboss.org
Author: snjeza
Date: 2011-01-06 12:38:46 -0500 (Thu, 06 Jan 2011)
New Revision: 27950
Modified:
trunk/seam/plugins/org.jboss.tools.seam.core/src/org/jboss/tools/seam/internal/core/project/facet/Seam2FacetInstallDelegate.java
trunk/seam/plugins/org.jboss.tools.seam.core/src/org/jboss/tools/seam/internal/core/project/facet/SeamFacetAbstractInstallDelegate.java
trunk/seam/plugins/org.jboss.tools.seam.core/src/org/jboss/tools/seam/internal/core/project/facet/SeamFacetInstallDelegate.java
Log:
JBIDE-7932 New Seam EAR project fails to deploy to JBoss AS 6 CR1
Modified: trunk/seam/plugins/org.jboss.tools.seam.core/src/org/jboss/tools/seam/internal/core/project/facet/Seam2FacetInstallDelegate.java
===================================================================
--- trunk/seam/plugins/org.jboss.tools.seam.core/src/org/jboss/tools/seam/internal/core/project/facet/Seam2FacetInstallDelegate.java 2011-01-06 16:02:51 UTC (rev 27949)
+++ trunk/seam/plugins/org.jboss.tools.seam.core/src/org/jboss/tools/seam/internal/core/project/facet/Seam2FacetInstallDelegate.java 2011-01-06 17:38:46 UTC (rev 27950)
@@ -20,6 +20,7 @@
import org.eclipse.core.runtime.IProgressMonitor;
import org.eclipse.emf.common.util.EList;
import org.eclipse.jst.javaee.web.WebApp;
+import org.eclipse.jst.jsf.core.JSFVersion;
import org.eclipse.jst.jsf.facesconfig.emf.ApplicationType;
import org.eclipse.jst.jsf.facesconfig.emf.DefaultLocaleType;
import org.eclipse.jst.jsf.facesconfig.emf.FacesConfigFactory;
@@ -258,7 +259,13 @@
* @see org.jboss.tools.seam.internal.core.project.facet.SeamFacetAbstractInstallDelegate#configure(org.eclipse.jst.javaee.web.WebApp)
*/
@Override
- protected void configure(WebApp webApp) {
+ protected void configure(WebApp webApp, IProject project) {
+ JSFVersion jsfVersion = JSFVersion.valueOfProject(project);
+
+ if (JSFVersion.V2_0.compareTo(jsfVersion) > 0) {
+ createOrUpdateContextParam(webApp, ORG_JBOSS_JBOSSFACES_JSF_CONFIG_NAME,
+ MOJARRA_1_2);
+ }
// Ajax4jsf
createOrUpdateContextParam(webApp, ORG_RICHFACES_SKIN,
ORG_RICHFACES_SKIN_VALUE);
Modified: trunk/seam/plugins/org.jboss.tools.seam.core/src/org/jboss/tools/seam/internal/core/project/facet/SeamFacetAbstractInstallDelegate.java
===================================================================
--- trunk/seam/plugins/org.jboss.tools.seam.core/src/org/jboss/tools/seam/internal/core/project/facet/SeamFacetAbstractInstallDelegate.java 2011-01-06 16:02:51 UTC (rev 27949)
+++ trunk/seam/plugins/org.jboss.tools.seam.core/src/org/jboss/tools/seam/internal/core/project/facet/SeamFacetAbstractInstallDelegate.java 2011-01-06 17:38:46 UTC (rev 27950)
@@ -106,6 +106,8 @@
public abstract class SeamFacetAbstractInstallDelegate implements ILogListener,
IDelegate,ISeamFacetDataModelProperties {
+ public static final String MOJARRA_1_2 = "Mojarra-1.2"; //$NON-NLS-1$
+ public static final String ORG_JBOSS_JBOSSFACES_JSF_CONFIG_NAME = "org.jboss.jbossfaces.JSF_CONFIG_NAME"; //$NON-NLS-1$
public static String ORG_RICHFACES_SKIN = "org.richfaces.SKIN"; //$NON-NLS-1$
public static String ORG_RICHFACES_SKIN_VALUE = "blueSky"; //$NON-NLS-1$
public static String ORG_JBOSS_SEAM_SERVLET_SEAMLISTENER = "org.jboss.seam.servlet.SeamListener"; //$NON-NLS-1$
@@ -1231,7 +1233,7 @@
*/
abstract protected void configureFacesConfigXml(final IProject project, IProgressMonitor monitor, String webConfigName);
- protected abstract void configure(WebApp webApp);
+ protected abstract void configure(WebApp webApp, IProject project);
protected WebApp configureWebXml(final IProject project) {
IModelProvider modelProvider = ModelProviderManager
@@ -1258,7 +1260,7 @@
return;
}
WebApp webApp = (WebApp) modelObject;
- configure(webApp);
+ configure(webApp, project);
}
}, modelPath);
Modified: trunk/seam/plugins/org.jboss.tools.seam.core/src/org/jboss/tools/seam/internal/core/project/facet/SeamFacetInstallDelegate.java
===================================================================
--- trunk/seam/plugins/org.jboss.tools.seam.core/src/org/jboss/tools/seam/internal/core/project/facet/SeamFacetInstallDelegate.java 2011-01-06 16:02:51 UTC (rev 27949)
+++ trunk/seam/plugins/org.jboss.tools.seam.core/src/org/jboss/tools/seam/internal/core/project/facet/SeamFacetInstallDelegate.java 2011-01-06 17:38:46 UTC (rev 27950)
@@ -21,6 +21,7 @@
import org.eclipse.jst.javaee.core.JavaeeFactory;
import org.eclipse.jst.javaee.web.Filter;
import org.eclipse.jst.javaee.web.WebApp;
+import org.eclipse.jst.jsf.core.JSFVersion;
import org.eclipse.jst.jsf.facesconfig.emf.ApplicationType;
import org.eclipse.jst.jsf.facesconfig.emf.FacesConfigFactory;
import org.eclipse.jst.jsf.facesconfig.emf.FacesConfigType;
@@ -239,7 +240,7 @@
* @see org.jboss.tools.seam.internal.core.project.facet.SeamFacetAbstractInstallDelegate#configure(org.eclipse.jst.javaee.web.WebApp)
*/
@Override
- protected void configure(WebApp webApp) {
+ protected void configure(WebApp webApp, IProject project) {
// Ajax4jsf (must come first!)
// FIXME supposing that the Ajax4jsf filter must come before the Seam filter
createOrUpdateFilter(webApp,
@@ -251,6 +252,12 @@
ORG_AJAX4JSF_FILTER_NAME,
ORG_AJAX4JSF_FILTER_MAPPING);
+ JSFVersion jsfVersion = JSFVersion.valueOfProject(project);
+
+ if (JSFVersion.V2_0.compareTo(jsfVersion) > 0) {
+ createOrUpdateContextParam(webApp, ORG_JBOSS_JBOSSFACES_JSF_CONFIG_NAME,
+ MOJARRA_1_2);
+ }
createOrUpdateContextParam(webApp, ORG_AJAX4JSF_VIEW_HANDLERS,
ORG_JBOSS_SEAM_UI_SEAMFACELETVIEWHANDLER);
createOrUpdateContextParam(webApp, ORG_AJAX4JSF_SKIN,
13 years, 5 months
JBoss Tools SVN: r27949 - trunk/documentation/qa/docs/Test_Cases.
by jbosstools-commits@lists.jboss.org
Author: vpakan(a)redhat.com
Date: 2011-01-06 11:02:51 -0500 (Thu, 06 Jan 2011)
New Revision: 27949
Modified:
trunk/documentation/qa/docs/Test_Cases/VPEtests.doc
Log:
Automated tests for JSF Tags
Modified: trunk/documentation/qa/docs/Test_Cases/VPEtests.doc
===================================================================
(Binary files differ)
13 years, 5 months
JBoss Tools SVN: r27948 - trunk/vpe/tests/org.jboss.tools.vpe.ui.bot.test/src/org/jboss/tools/vpe/ui/bot/test/editor/tags.
by jbosstools-commits@lists.jboss.org
Author: vpakan(a)redhat.com
Date: 2011-01-06 10:53:56 -0500 (Thu, 06 Jan 2011)
New Revision: 27948
Modified:
trunk/vpe/tests/org.jboss.tools.vpe.ui.bot.test/src/org/jboss/tools/vpe/ui/bot/test/editor/tags/JSFTagsTest.java
Log:
Added testSelectManyCheckbox test.
Modified: trunk/vpe/tests/org.jboss.tools.vpe.ui.bot.test/src/org/jboss/tools/vpe/ui/bot/test/editor/tags/JSFTagsTest.java
===================================================================
--- trunk/vpe/tests/org.jboss.tools.vpe.ui.bot.test/src/org/jboss/tools/vpe/ui/bot/test/editor/tags/JSFTagsTest.java 2011-01-06 14:51:16 UTC (rev 27947)
+++ trunk/vpe/tests/org.jboss.tools.vpe.ui.bot.test/src/org/jboss/tools/vpe/ui/bot/test/editor/tags/JSFTagsTest.java 2011-01-06 15:53:56 UTC (rev 27948)
@@ -248,8 +248,57 @@
JSFTagsTest.TEST_PAGE_NAME);
}
/**
- * Tests h:inputText Tag
+ * Tests h:selectManyCheckbox Tag
*/
+ public void testSelectManyCheckbox(){
+ final String itemLabel = "item1";
+ jspEditor.setText("<%@ taglib uri=\"http://java.sun.com/jsf/html\" prefix=\"h\" %>\n" +
+ "<%@ taglib uri=\"http://java.sun.com/jsf/core\" prefix=\"f\" %>\n" +
+ "<html>\n" +
+ " <head>\n" +
+ " </head>\n" +
+ " <body>\n" +
+ " <f:view>\n" +
+ " <h:form id=\"form1\">\n" +
+ " <h:selectManyCheckbox value=\"checkbox\">\n" +
+ " <f:selectItem itemLabel=\"" + itemLabel + "\"/>\n" +
+ " </h:selectManyCheckbox>\n" +
+ " </h:form>\n" +
+ " </f:view>\n" +
+ " </body>\n" +
+ "</html>");
+ jspEditor.save();
+ bot.sleep(Timing.time3S());
+ assertVisualEditorContains(webBrowser,
+ "INPUT",
+ new String[]{"type"},
+ new String[]{"checkbox"},
+ JSFTagsTest.TEST_PAGE_NAME);
+ assertVisualEditorContainsNodeWithValue(webBrowser, itemLabel, JSFTagsTest.TEST_PAGE_NAME);
+ // check tag selection
+ webBrowser.selectDomNode(webBrowser.getDomNodeByTagName("INPUT"), 0);
+ bot.sleep(Timing.time3S());
+ String selectedText = jspEditor.getSelection();
+ final String hasToStartWith = "<f:selectItem itemLabel=\"" + itemLabel + "\"";
+ assertTrue("Selected text in Source Pane has to start with '" + hasToStartWith + "'" +
+ "\nbut it is '" + selectedText + "'",
+ selectedText.trim().startsWith(hasToStartWith));
+ // check text insertion
+ webBrowser.selectDomNode(webBrowser.getDomNodeByTagName("LABEL"), 0);
+ bot.sleep(Timing.time3S());
+ webBrowser.setFocus();
+ final String insertText = "insertText";
+ KeyboardHelper.typeBasicStringUsingAWT(insertText);
+ jspEditor.save();
+ bot.sleep(Timing.time3S());
+ assertVisualEditorContainsNodeWithValue(webBrowser, insertText + itemLabel, JSFTagsTest.TEST_PAGE_NAME);
+ assertSourceEditorContains(jspEditor.getText(),
+ "<f:selectItem itemLabel=\"" + insertText + itemLabel + "\"",
+ JSFTagsTest.TEST_PAGE_NAME);
+ }
+ /**
+ * Tests h:selectOneRadio Tag
+ */
public void testSelectOneRadio(){
final String itemLabel = "item1";
jspEditor.setText("<%@ taglib uri=\"http://java.sun.com/jsf/html\" prefix=\"h\" %>\n" +
13 years, 5 months
JBoss Tools SVN: r27947 - in trunk/vpe/tests/org.jboss.tools.vpe.ui.bot.test/src/org/jboss/tools/vpe/ui/bot/test: editor and 2 other directories.
by jbosstools-commits@lists.jboss.org
Author: vpakan(a)redhat.com
Date: 2011-01-06 09:51:16 -0500 (Thu, 06 Jan 2011)
New Revision: 27947
Added:
trunk/vpe/tests/org.jboss.tools.vpe.ui.bot.test/src/org/jboss/tools/vpe/ui/bot/test/editor/tags/JSFTagsTest.java
Modified:
trunk/vpe/tests/org.jboss.tools.vpe.ui.bot.test/src/org/jboss/tools/vpe/ui/bot/test/VPEAllBotTests.java
trunk/vpe/tests/org.jboss.tools.vpe.ui.bot.test/src/org/jboss/tools/vpe/ui/bot/test/editor/VPEEditorTestCase.java
trunk/vpe/tests/org.jboss.tools.vpe.ui.bot.test/src/org/jboss/tools/vpe/ui/bot/test/editor/tags/CoreHTMLTagsTest.java
trunk/vpe/tests/org.jboss.tools.vpe.ui.bot.test/src/org/jboss/tools/vpe/ui/bot/test/tools/SWTBotWebBrowser.java
Log:
Added JSFTagsTest
Modified: trunk/vpe/tests/org.jboss.tools.vpe.ui.bot.test/src/org/jboss/tools/vpe/ui/bot/test/VPEAllBotTests.java
===================================================================
--- trunk/vpe/tests/org.jboss.tools.vpe.ui.bot.test/src/org/jboss/tools/vpe/ui/bot/test/VPEAllBotTests.java 2011-01-06 14:47:37 UTC (rev 27946)
+++ trunk/vpe/tests/org.jboss.tools.vpe.ui.bot.test/src/org/jboss/tools/vpe/ui/bot/test/VPEAllBotTests.java 2011-01-06 14:51:16 UTC (rev 27947)
@@ -34,6 +34,7 @@
import org.jboss.tools.vpe.ui.bot.test.editor.preferences.ShowSelectionTagBarTest;
import org.jboss.tools.vpe.ui.bot.test.editor.selectionbar.SelectionBarTest;
import org.jboss.tools.vpe.ui.bot.test.editor.tags.CoreHTMLTagsTest;
+import org.jboss.tools.vpe.ui.bot.test.editor.tags.JSFTagsTest;
import org.jboss.tools.vpe.ui.bot.test.jbide.JBIDE4556Test;
import org.jboss.tools.vpe.ui.bot.test.palette.CancelTagLibDefenitionTest;
import org.jboss.tools.vpe.ui.bot.test.palette.ImportTagsFromTLDFileTest;
@@ -98,6 +99,7 @@
suite.addTestSuite(StylesOnThePageTest.class);
suite.addTestSuite(TextSelectionTest.class);
suite.addTestSuite(CoreHTMLTagsTest.class);
+ suite.addTestSuite(JSFTagsTest.class);
return new TestSetup(suite);
}
}
Modified: trunk/vpe/tests/org.jboss.tools.vpe.ui.bot.test/src/org/jboss/tools/vpe/ui/bot/test/editor/VPEEditorTestCase.java
===================================================================
--- trunk/vpe/tests/org.jboss.tools.vpe.ui.bot.test/src/org/jboss/tools/vpe/ui/bot/test/editor/VPEEditorTestCase.java 2011-01-06 14:47:37 UTC (rev 27946)
+++ trunk/vpe/tests/org.jboss.tools.vpe.ui.bot.test/src/org/jboss/tools/vpe/ui/bot/test/editor/VPEEditorTestCase.java 2011-01-06 14:51:16 UTC (rev 27947)
@@ -214,5 +214,27 @@
valueToContain));
}
-
+ /**
+ * Asserts if Visual Editor doesn't contain node with particular attributes
+ * @param webBrowser
+ * @param nodeNameToContain
+ * @param attributeNames
+ * @param attributeValues
+ * @param fileName
+ */
+ protected static void assertVisualEditorNotContain (SWTBotWebBrowser webBrowser,
+ String nodeNameToContain,
+ String[] attributeNames, String[] attributeValues,
+ String fileName){
+
+ assertFalse("Visual Representation of file " + fileName
+ + " cannot contain "
+ + nodeNameToContain
+ + " node but it does",
+ webBrowser.containsNodeWithNameAndAttributes(webBrowser.getMozillaEditor().getDomDocument(),
+ nodeNameToContain,
+ attributeNames,
+ attributeValues));
+
+ }
}
Modified: trunk/vpe/tests/org.jboss.tools.vpe.ui.bot.test/src/org/jboss/tools/vpe/ui/bot/test/editor/tags/CoreHTMLTagsTest.java
===================================================================
--- trunk/vpe/tests/org.jboss.tools.vpe.ui.bot.test/src/org/jboss/tools/vpe/ui/bot/test/editor/tags/CoreHTMLTagsTest.java 2011-01-06 14:47:37 UTC (rev 27946)
+++ trunk/vpe/tests/org.jboss.tools.vpe.ui.bot.test/src/org/jboss/tools/vpe/ui/bot/test/editor/tags/CoreHTMLTagsTest.java 2011-01-06 14:51:16 UTC (rev 27947)
@@ -58,14 +58,14 @@
"BODY",
new String[]{"style"},
new String[]{"color: red; text-align: center; background-color: green;"},
- CoreHTMLTagsTest.PAGE_TEXT);
+ CoreHTMLTagsTest.TEST_PAGE_NAME);
// check after refresh
bot.toolbarButtonWithTooltip(IDELabel.ToolbarButton.REFRESH).click();
assertVisualEditorContains(webBrowser,
"BODY",
new String[]{"style"},
new String[]{"color: red; text-align: center; background-color: green;"},
- CoreHTMLTagsTest.PAGE_TEXT);
+ CoreHTMLTagsTest.TEST_PAGE_NAME);
}
Added: trunk/vpe/tests/org.jboss.tools.vpe.ui.bot.test/src/org/jboss/tools/vpe/ui/bot/test/editor/tags/JSFTagsTest.java
===================================================================
--- trunk/vpe/tests/org.jboss.tools.vpe.ui.bot.test/src/org/jboss/tools/vpe/ui/bot/test/editor/tags/JSFTagsTest.java (rev 0)
+++ trunk/vpe/tests/org.jboss.tools.vpe.ui.bot.test/src/org/jboss/tools/vpe/ui/bot/test/editor/tags/JSFTagsTest.java 2011-01-06 14:51:16 UTC (rev 27947)
@@ -0,0 +1,299 @@
+/*******************************************************************************
+
+ * Copyright (c) 2007-2011 Exadel, Inc. and 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:
+ * Exadel, Inc. and Red Hat, Inc. - initial API and implementation
+ ******************************************************************************/
+package org.jboss.tools.vpe.ui.bot.test.editor.tags;
+
+import java.awt.event.KeyEvent;
+
+import org.jboss.tools.ui.bot.ext.SWTBotExt;
+import org.jboss.tools.ui.bot.ext.Timing;
+import org.jboss.tools.ui.bot.ext.helper.KeyboardHelper;
+import org.jboss.tools.ui.bot.ext.parts.SWTBotEditorExt;
+import org.jboss.tools.vpe.ui.bot.test.editor.VPEEditorTestCase;
+import org.jboss.tools.vpe.ui.bot.test.tools.SWTBotWebBrowser;
+/**
+ * Tests JSF Tags behavior
+ * @author vlado pakan
+ *
+ */
+public class JSFTagsTest extends VPEEditorTestCase {
+
+ private static final String TEST_PAGE_NAME = "JSFTagsTest.jsp";
+
+ private SWTBotEditorExt jspEditor;
+ private SWTBotWebBrowser webBrowser;
+ private SWTBotExt botExt;
+
+ public JSFTagsTest() {
+ super();
+ botExt = new SWTBotExt();
+ }
+ @Override
+ protected void setUp() throws Exception {
+ super.setUp();
+ eclipse.maximizeActiveShell();
+ createJspPage(JSFTagsTest.TEST_PAGE_NAME);
+ jspEditor = botExt.swtBotEditorExtByTitle(JSFTagsTest.TEST_PAGE_NAME);
+ webBrowser = new SWTBotWebBrowser(JSFTagsTest.TEST_PAGE_NAME,botExt);
+ }
+ /**
+ * Tests h:commandLink Tag
+ */
+ public void testCommandLinkTag(){
+
+ jspEditor.setText("<%@ taglib uri=\"http://java.sun.com/jsf/html\" prefix=\"h\" %>\n" +
+ "<%@ taglib uri=\"http://java.sun.com/jsf/core\" prefix=\"f\" %>\n" +
+ "<html>\n" +
+ " <head>\n" +
+ " </head>\n" +
+ " <body>\n" +
+ " <f:view>\n" +
+ " <h:form id=\"form1\">\n" +
+ " <h:commandLink value=\"Command Link\"/>\n" +
+ " </h:form>\n" +
+ " </f:view>\n" +
+ " </body>\n" +
+ "</html>");
+ jspEditor.save();
+ bot.sleep(Timing.time3S());
+ assertVisualEditorContains(webBrowser,
+ "A",
+ new String[]{"title"},
+ new String[]{"h:commandLink value: Command Link"},
+ JSFTagsTest.TEST_PAGE_NAME);
+ assertVisualEditorContainsNodeWithValue(webBrowser, "Command Link", JSFTagsTest.TEST_PAGE_NAME);
+ // move h:commandLink from h:form tag and check correct behavior
+ jspEditor.setText("<%@ taglib uri=\"http://java.sun.com/jsf/html\" prefix=\"h\" %>\n" +
+ "<%@ taglib uri=\"http://java.sun.com/jsf/core\" prefix=\"f\" %>\n" +
+ "<html>\n" +
+ " <head>\n" +
+ " </head>\n" +
+ " <body>\n" +
+ " <h:commandLink value=\"Command Link\"/>\n" +
+ " </body>\n" +
+ "</html>");
+ jspEditor.save();
+ bot.sleep(Timing.time3S());
+ assertVisualEditorNotContain(webBrowser,
+ "A",
+ null,
+ null,
+ JSFTagsTest.TEST_PAGE_NAME);
+ assertVisualEditorContainsNodeWithValue(webBrowser, "Command Link", JSFTagsTest.TEST_PAGE_NAME);
+ assertVisualEditorContainsNodeWithValue(webBrowser, ": This link is disabled as it is not nested within a JSF form.", JSFTagsTest.TEST_PAGE_NAME);
+
+ }
+
+ @Override
+ protected void closeUnuseDialogs() {
+
+ }
+
+ @Override
+ protected boolean isUnuseDialogOpened() {
+ return false;
+ }
+ @Override
+ protected void tearDown() throws Exception {
+ jspEditor.close();
+ super.tearDown();
+ }
+ /**
+ * Tests h:inputText Tag
+ */
+ public void testInputTextTag(){
+
+ jspEditor.setText("<%@ taglib uri=\"http://java.sun.com/jsf/html\" prefix=\"h\" %>\n" +
+ "<%@ taglib uri=\"http://java.sun.com/jsf/core\" prefix=\"f\" %>\n" +
+ "<html>\n" +
+ " <head>\n" +
+ " </head>\n" +
+ " <body>\n" +
+ " <f:view>\n" +
+ " <h:inputText/>\n" +
+ " </f:view>\n" +
+ " </body>\n" +
+ "</html>");
+ jspEditor.save();
+ bot.sleep(Timing.time3S());
+ assertVisualEditorContains(webBrowser,
+ "INPUT",
+ new String[]{"title"},
+ new String[]{"h:inputText"},
+ JSFTagsTest.TEST_PAGE_NAME);
+ // check tag selection
+ webBrowser.selectDomNode(webBrowser.getDomNodeByTagName("INPUT"), 0);
+ bot.sleep(Timing.time3S());
+ String selectedText = jspEditor.getSelection();
+ final String hasToStartWith = "<h:inputText";
+ assertTrue("Selected text in Source Pane has to start with '" + hasToStartWith + "'" +
+ "\nbut it is '" + selectedText + "'",
+ selectedText.trim().startsWith(hasToStartWith));
+ // check text insertion
+ webBrowser.setFocus();
+ final String insertText = "insertText";
+ KeyboardHelper.typeBasicStringUsingAWT(insertText);
+ jspEditor.save();
+ bot.sleep(Timing.time3S());
+ assertVisualEditorContains(webBrowser,
+ "INPUT",
+ new String[]{"title","value"},
+ new String[]{"h:inputText value: " + insertText,insertText},
+ JSFTagsTest.TEST_PAGE_NAME);
+ assertSourceEditorContains(jspEditor.getText(),
+ "<h:inputText value=\"" + insertText + "\"",
+ JSFTagsTest.TEST_PAGE_NAME);
+ }
+ /**
+ * Tests h:inputTextArea Tag
+ */
+ public void testInputTextAreaTag(){
+
+ jspEditor.setText("<%@ taglib uri=\"http://java.sun.com/jsf/html\" prefix=\"h\" %>\n" +
+ "<%@ taglib uri=\"http://java.sun.com/jsf/core\" prefix=\"f\" %>\n" +
+ "<html>\n" +
+ " <head>\n" +
+ " </head>\n" +
+ " <body>\n" +
+ " <f:view>\n" +
+ " <h:inputTextarea/>\n" +
+ " </f:view>\n" +
+ " </body>\n" +
+ "</html>");
+ jspEditor.save();
+ bot.sleep(Timing.time3S());
+ assertVisualEditorContains(webBrowser,
+ "TEXTAREA",
+ new String[]{"title"},
+ new String[]{"h:inputTextarea"},
+ JSFTagsTest.TEST_PAGE_NAME);
+ // check tag selection
+ webBrowser.selectDomNode(webBrowser.getDomNodeByTagName("TEXTAREA"), 0);
+ bot.sleep(Timing.time3S());
+ String selectedText = jspEditor.getSelection();
+ final String hasToStartWith = "<h:inputTextarea";
+ assertTrue("Selected text in Source Pane has to start with '" + hasToStartWith + "'" +
+ "\nbut it is '" + selectedText + "'",
+ selectedText.trim().startsWith(hasToStartWith));
+ // check text insertion
+ webBrowser.setFocus();
+ final String insertText = "insertText";
+ KeyboardHelper.typeBasicStringUsingAWT(insertText);
+ jspEditor.save();
+ bot.sleep(Timing.time3S());
+ assertVisualEditorContains(webBrowser,
+ "TEXTAREA",
+ new String[]{"title"},
+ new String[]{"h:inputTextarea value: " + insertText},
+ JSFTagsTest.TEST_PAGE_NAME);
+ assertVisualEditorContainsNodeWithValue(webBrowser, insertText, JSFTagsTest.TEST_PAGE_NAME);
+ assertSourceEditorContains(jspEditor.getText(),
+ "<h:inputTextarea value=\"" + insertText + "\"",
+ JSFTagsTest.TEST_PAGE_NAME);
+ }
+ /**
+ * Tests h:outputText Tag
+ */
+ public void testOutputTextTag(){
+
+ final String outputText = "Output Text";
+ final String normalText = "Normal Text";
+ jspEditor.setText("<%@ taglib uri=\"http://java.sun.com/jsf/html\" prefix=\"h\" %>\n" +
+ "<%@ taglib uri=\"http://java.sun.com/jsf/core\" prefix=\"f\" %>\n" +
+ "<html>\n" +
+ " <head>\n" +
+ " </head>\n" +
+ " <body>\n" +
+ " <f:view>\n" +
+ " <h:form id=\"form1\">\n" +
+ " <h:outputText value=\"" + outputText + "\"/>" + normalText + "\n" +
+ " </h:form>\n" +
+ " </f:view>\n" +
+ " </body>\n" +
+ "</html>");
+ jspEditor.save();
+ bot.sleep(Timing.time3S());
+ assertVisualEditorContainsNodeWithValue(webBrowser,
+ outputText,
+ JSFTagsTest.TEST_PAGE_NAME);
+ assertVisualEditorContainsNodeWithValue(webBrowser,
+ normalText,
+ JSFTagsTest.TEST_PAGE_NAME);
+ // check editing via Visual Pane
+ webBrowser.selectDomNode(webBrowser.getDomNodeByTagName("SPAN"), 0);
+ webBrowser.setFocus();
+ final String insertText = "inserted";
+ KeyboardHelper.typeKeyCodeUsingAWT(KeyEvent.VK_RIGHT);
+ KeyboardHelper.typeKeyCodeUsingAWT(KeyEvent.VK_LEFT);
+ KeyboardHelper.typeBasicStringUsingAWT(insertText);
+ jspEditor.save();
+ bot.sleep(Timing.time3S());
+ assertSourceEditorContains(jspEditor.getText(),
+ "<h:outputText value=\"" + insertText + outputText + "\"",
+ JSFTagsTest.TEST_PAGE_NAME);
+ KeyboardHelper.typeKeyCodeUsingAWTRepeately(KeyEvent.VK_RIGHT,outputText.length() + normalText.length());
+ KeyboardHelper.typeBasicStringUsingAWT(insertText);
+ jspEditor.save();
+ bot.sleep(Timing.time3S());
+ assertSourceEditorContains(jspEditor.getText(),
+ normalText + insertText,
+ JSFTagsTest.TEST_PAGE_NAME);
+ }
+ /**
+ * Tests h:inputText Tag
+ */
+ public void testSelectOneRadio(){
+ final String itemLabel = "item1";
+ jspEditor.setText("<%@ taglib uri=\"http://java.sun.com/jsf/html\" prefix=\"h\" %>\n" +
+ "<%@ taglib uri=\"http://java.sun.com/jsf/core\" prefix=\"f\" %>\n" +
+ "<html>\n" +
+ " <head>\n" +
+ " </head>\n" +
+ " <body>\n" +
+ " <f:view>\n" +
+ " <h:form id=\"form1\">\n" +
+ " <h:selectOneRadio value=\"radio\">\n" +
+ " <f:selectItem itemLabel=\"" + itemLabel + "\"/>\n" +
+ " </h:selectOneRadio>\n" +
+ " </h:form>\n" +
+ " </f:view>\n" +
+ " </body>\n" +
+ "</html>");
+ jspEditor.save();
+ bot.sleep(Timing.time3S());
+ assertVisualEditorContains(webBrowser,
+ "INPUT",
+ new String[]{"type"},
+ new String[]{"radio"},
+ JSFTagsTest.TEST_PAGE_NAME);
+ assertVisualEditorContainsNodeWithValue(webBrowser, itemLabel, JSFTagsTest.TEST_PAGE_NAME);
+ // check tag selection
+ webBrowser.selectDomNode(webBrowser.getDomNodeByTagName("INPUT"), 0);
+ bot.sleep(Timing.time3S());
+ String selectedText = jspEditor.getSelection();
+ final String hasToStartWith = "<f:selectItem itemLabel=\"" + itemLabel + "\"";
+ assertTrue("Selected text in Source Pane has to start with '" + hasToStartWith + "'" +
+ "\nbut it is '" + selectedText + "'",
+ selectedText.trim().startsWith(hasToStartWith));
+ // check text insertion
+ webBrowser.selectDomNode(webBrowser.getDomNodeByTagName("LABEL"), 0);
+ bot.sleep(Timing.time3S());
+ webBrowser.setFocus();
+ final String insertText = "insertText";
+ KeyboardHelper.typeBasicStringUsingAWT(insertText);
+ jspEditor.save();
+ bot.sleep(Timing.time3S());
+ assertVisualEditorContainsNodeWithValue(webBrowser, insertText + itemLabel, JSFTagsTest.TEST_PAGE_NAME);
+ assertSourceEditorContains(jspEditor.getText(),
+ "<f:selectItem itemLabel=\"" + insertText + itemLabel + "\"",
+ JSFTagsTest.TEST_PAGE_NAME);
+ }
+}
Property changes on: trunk/vpe/tests/org.jboss.tools.vpe.ui.bot.test/src/org/jboss/tools/vpe/ui/bot/test/editor/tags/JSFTagsTest.java
___________________________________________________________________
Name: svn:mime-type
+ text/plain
Modified: trunk/vpe/tests/org.jboss.tools.vpe.ui.bot.test/src/org/jboss/tools/vpe/ui/bot/test/tools/SWTBotWebBrowser.java
===================================================================
--- trunk/vpe/tests/org.jboss.tools.vpe.ui.bot.test/src/org/jboss/tools/vpe/ui/bot/test/tools/SWTBotWebBrowser.java 2011-01-06 14:47:37 UTC (rev 27946)
+++ trunk/vpe/tests/org.jboss.tools.vpe.ui.bot.test/src/org/jboss/tools/vpe/ui/bot/test/tools/SWTBotWebBrowser.java 2011-01-06 14:51:16 UTC (rev 27947)
@@ -408,7 +408,8 @@
for (int index = 0 ; index < attributeNames.length && attributesAreEqual; index++){
nsIDOMNode attributeNode = attributesMap.getNamedItem(attributeNames[index]);
if (attributeNode != null){
- if (!attributeNode.getNodeValue().equalsIgnoreCase(attributeValues[index])){
+ if (!SWTBotWebBrowser.stripTextFromSpecChars(attributeNode.getNodeValue())
+ .equalsIgnoreCase(attributeValues[index])){
attributesAreEqual = false;
}
}
@@ -468,7 +469,7 @@
String nodeValue = node.getNodeValue();
- if (nodeValue != null && nodeValue.equals(searchText)) {
+ if (nodeValue != null && SWTBotWebBrowser.stripTextFromSpecChars(nodeValue).equals(searchText)) {
result = true;
}
else {
@@ -782,5 +783,12 @@
return result;
}
-
+ /**
+ * Returns inputText striped from spaces, tabs and EOL
+ * @param inputText
+ * @return String
+ */
+ protected static String stripTextFromSpecChars(String inputText){
+ return inputText.replaceAll("\n", " ").replaceAll("\t", "").trim();
+ }
}
13 years, 5 months
JBoss Tools SVN: r27946 - trunk/tests/plugins/org.jboss.tools.ui.bot.ext/src/org/jboss/tools/ui/bot/ext/config.
by jbosstools-commits@lists.jboss.org
Author: vpakan(a)redhat.com
Date: 2011-01-06 09:47:37 -0500 (Thu, 06 Jan 2011)
New Revision: 27946
Modified:
trunk/tests/plugins/org.jboss.tools.ui.bot.ext/src/org/jboss/tools/ui/bot/ext/config/TestConfigurator.java
Log:
Remove unused warning
Modified: trunk/tests/plugins/org.jboss.tools.ui.bot.ext/src/org/jboss/tools/ui/bot/ext/config/TestConfigurator.java
===================================================================
--- trunk/tests/plugins/org.jboss.tools.ui.bot.ext/src/org/jboss/tools/ui/bot/ext/config/TestConfigurator.java 2011-01-06 14:09:41 UTC (rev 27945)
+++ trunk/tests/plugins/org.jboss.tools.ui.bot.ext/src/org/jboss/tools/ui/bot/ext/config/TestConfigurator.java 2011-01-06 14:47:37 UTC (rev 27946)
@@ -2,7 +2,6 @@
import java.io.File;
import java.io.FileInputStream;
-import java.io.FileNotFoundException;
import java.io.IOException;
import java.util.ArrayList;
import java.util.Collections;
13 years, 5 months
JBoss Tools SVN: r27945 - trunk/deltacloud/plugins/org.jboss.tools.deltacloud.ui/src/org/jboss/tools/deltacloud/ui/views/cloud.
by jbosstools-commits@lists.jboss.org
Author: adietish
Date: 2011-01-06 09:09:41 -0500 (Thu, 06 Jan 2011)
New Revision: 27945
Modified:
trunk/deltacloud/plugins/org.jboss.tools.deltacloud.ui/src/org/jboss/tools/deltacloud/ui/views/cloud/ImagesCategoryItem.java
trunk/deltacloud/plugins/org.jboss.tools.deltacloud.ui/src/org/jboss/tools/deltacloud/ui/views/cloud/InstancesCategoryItem.java
Log:
[JBIDE-8061] now adding children in background thread, relying on property update for refresh only
Modified: trunk/deltacloud/plugins/org.jboss.tools.deltacloud.ui/src/org/jboss/tools/deltacloud/ui/views/cloud/ImagesCategoryItem.java
===================================================================
--- trunk/deltacloud/plugins/org.jboss.tools.deltacloud.ui/src/org/jboss/tools/deltacloud/ui/views/cloud/ImagesCategoryItem.java 2011-01-06 14:07:35 UTC (rev 27944)
+++ trunk/deltacloud/plugins/org.jboss.tools.deltacloud.ui/src/org/jboss/tools/deltacloud/ui/views/cloud/ImagesCategoryItem.java 2011-01-06 14:09:41 UTC (rev 27945)
@@ -76,7 +76,6 @@
DeltaCloud cloud = (DeltaCloud) event.getSource();
DeltaCloudImage[] newImages = (DeltaCloudImage[]) event.getNewValue();
try {
- System.err.println("images updated");
replaceCloudElements(cloud, newImages);
} catch (DeltaCloudException e) {
// TODO: internationalize strings
Modified: trunk/deltacloud/plugins/org.jboss.tools.deltacloud.ui/src/org/jboss/tools/deltacloud/ui/views/cloud/InstancesCategoryItem.java
===================================================================
--- trunk/deltacloud/plugins/org.jboss.tools.deltacloud.ui/src/org/jboss/tools/deltacloud/ui/views/cloud/InstancesCategoryItem.java 2011-01-06 14:07:35 UTC (rev 27944)
+++ trunk/deltacloud/plugins/org.jboss.tools.deltacloud.ui/src/org/jboss/tools/deltacloud/ui/views/cloud/InstancesCategoryItem.java 2011-01-06 14:09:41 UTC (rev 27945)
@@ -82,7 +82,6 @@
DeltaCloud cloud = (DeltaCloud) event.getSource();
DeltaCloudInstance[] newInstances = (DeltaCloudInstance[]) event.getNewValue();
try {
- System.err.println("images updated");
replaceCloudElements(cloud, newInstances);
} catch (DeltaCloudException e) {
// TODO: internationalize strings
13 years, 5 months
JBoss Tools SVN: r27944 - in trunk/deltacloud/plugins/org.jboss.tools.deltacloud.ui: src/org/jboss/tools/deltacloud/ui/views/cloud and 1 other directory.
by jbosstools-commits@lists.jboss.org
Author: adietish
Date: 2011-01-06 09:07:35 -0500 (Thu, 06 Jan 2011)
New Revision: 27944
Modified:
trunk/deltacloud/plugins/org.jboss.tools.deltacloud.ui/ChangeLog
trunk/deltacloud/plugins/org.jboss.tools.deltacloud.ui/src/org/jboss/tools/deltacloud/ui/views/cloud/CloudElementCategoryItem.java
trunk/deltacloud/plugins/org.jboss.tools.deltacloud.ui/src/org/jboss/tools/deltacloud/ui/views/cloud/DeltaCloudViewItem.java
trunk/deltacloud/plugins/org.jboss.tools.deltacloud.ui/src/org/jboss/tools/deltacloud/ui/views/cloud/ImagesCategoryItem.java
trunk/deltacloud/plugins/org.jboss.tools.deltacloud.ui/src/org/jboss/tools/deltacloud/ui/views/cloud/InstancesCategoryItem.java
Log:
[JBIDE-8061] now adding children in background thread, relying on property update for refresh only
Modified: trunk/deltacloud/plugins/org.jboss.tools.deltacloud.ui/ChangeLog
===================================================================
--- trunk/deltacloud/plugins/org.jboss.tools.deltacloud.ui/ChangeLog 2011-01-06 13:08:56 UTC (rev 27943)
+++ trunk/deltacloud/plugins/org.jboss.tools.deltacloud.ui/ChangeLog 2011-01-06 14:07:35 UTC (rev 27944)
@@ -1,3 +1,12 @@
+2011-01-06 André Dietisheim <André Dietisheim@adietisheim-thinkpad>
+
+ * src/org/jboss/tools/deltacloud/ui/views/cloud/ImagesCategoryItem.java (.doRun):
+ * src/org/jboss/tools/deltacloud/ui/views/cloud/InstancesCategoryItem.java (.doRun):
+ * src/org/jboss/tools/deltacloud/ui/views/cloud/CloudElementCategoryItem.java
+ (getChildren):
+ (replaceCloudElements):
+ [JBIDE-8061] now adding children in background thread, relying on property update for refresh only
+
2011-01-05 André Dietisheim <André Dietisheim@adietisheim-thinkpad>
* src/org/jboss/tools/deltacloud/ui/views/CVMessages.properties:
Modified: trunk/deltacloud/plugins/org.jboss.tools.deltacloud.ui/src/org/jboss/tools/deltacloud/ui/views/cloud/CloudElementCategoryItem.java
===================================================================
--- trunk/deltacloud/plugins/org.jboss.tools.deltacloud.ui/src/org/jboss/tools/deltacloud/ui/views/cloud/CloudElementCategoryItem.java 2011-01-06 13:08:56 UTC (rev 27943)
+++ trunk/deltacloud/plugins/org.jboss.tools.deltacloud.ui/src/org/jboss/tools/deltacloud/ui/views/cloud/CloudElementCategoryItem.java 2011-01-06 14:07:35 UTC (rev 27944)
@@ -42,27 +42,26 @@
protected void setLoadingIndicator() {
clearChildren();
addChild(new LoadingItem(this, getViewer()));
-// refresh();
}
protected abstract void asyncLoadCloudElements();
- protected void addChildren(CLOUDELEMENT[] modelElements) {
- if (modelElements.length > NumericFoldingItem.FOLDING_SIZE) {
- addFoldedChildren(modelElements);
+ protected void addChildren(CLOUDELEMENT[] cloudElements) {
+ if (cloudElements.length > NumericFoldingItem.FOLDING_SIZE) {
+ addFoldedChildren(cloudElements);
} else {
- addChildren(getElements(modelElements, 0, modelElements.length));
+ addChildren(getElements(cloudElements, 0, cloudElements.length));
}
}
- protected void addFoldedChildren(CLOUDELEMENT[] modelElements) {
+ protected void addFoldedChildren(CLOUDELEMENT[] cloudElements) {
int min = 0;
int max = NumericFoldingItem.FOLDING_SIZE;
- int length = modelElements.length;
+ int length = cloudElements.length;
while (length > NumericFoldingItem.FOLDING_SIZE) {
NumericFoldingItem f = new NumericFoldingItem(min, max, this, getViewer());
addChild(f);
- f.addChildren(getElements(modelElements, min, max));
+ f.addChildren(getElements(cloudElements, min, max));
min += NumericFoldingItem.FOLDING_SIZE;
max += NumericFoldingItem.FOLDING_SIZE;
length -= NumericFoldingItem.FOLDING_SIZE;
@@ -70,13 +69,14 @@
if (length > 0) {
NumericFoldingItem f = new NumericFoldingItem(min, max, this, getViewer());
addChild(f);
- f.addChildren(getElements(modelElements, min, min + length));
+ f.addChildren(getElements(cloudElements, min, min + length));
}
}
- protected void onCloudElementsChanged(DeltaCloud cloud, CLOUDELEMENT[] cloudElements) throws DeltaCloudException {
+ protected void replaceCloudElements(DeltaCloud cloud, CLOUDELEMENT[] cloudElements) throws DeltaCloudException {
clearChildren();
addChildren(filter(cloudElements));
+ setChildrenInitialized(true); // unrequested update
refresh();
expand();
}
Modified: trunk/deltacloud/plugins/org.jboss.tools.deltacloud.ui/src/org/jboss/tools/deltacloud/ui/views/cloud/DeltaCloudViewItem.java
===================================================================
--- trunk/deltacloud/plugins/org.jboss.tools.deltacloud.ui/src/org/jboss/tools/deltacloud/ui/views/cloud/DeltaCloudViewItem.java 2011-01-06 13:08:56 UTC (rev 27943)
+++ trunk/deltacloud/plugins/org.jboss.tools.deltacloud.ui/src/org/jboss/tools/deltacloud/ui/views/cloud/DeltaCloudViewItem.java 2011-01-06 14:07:35 UTC (rev 27944)
@@ -187,6 +187,9 @@
});
}
+ protected void dispose() {
+ }
+
protected Display getDisplay() {
return viewer.getControl().getDisplay();
}
@@ -194,7 +197,4 @@
protected TreeViewer getViewer() {
return viewer;
}
-
- protected void dispose() {
- }
}
Modified: trunk/deltacloud/plugins/org.jboss.tools.deltacloud.ui/src/org/jboss/tools/deltacloud/ui/views/cloud/ImagesCategoryItem.java
===================================================================
--- trunk/deltacloud/plugins/org.jboss.tools.deltacloud.ui/src/org/jboss/tools/deltacloud/ui/views/cloud/ImagesCategoryItem.java 2011-01-06 13:08:56 UTC (rev 27943)
+++ trunk/deltacloud/plugins/org.jboss.tools.deltacloud.ui/src/org/jboss/tools/deltacloud/ui/views/cloud/ImagesCategoryItem.java 2011-01-06 14:07:35 UTC (rev 27944)
@@ -51,7 +51,8 @@
@Override
protected IStatus doRun(IProgressMonitor monitor) throws DeltaCloudException {
try {
- getCloud().getImages();
+ DeltaCloudImage[] images = getCloud().getImages();
+ replaceCloudElements(getModel(), images);
return Status.OK_STATUS;
} catch(DeltaCloudException e) {
clearChildren();
@@ -75,7 +76,8 @@
DeltaCloud cloud = (DeltaCloud) event.getSource();
DeltaCloudImage[] newImages = (DeltaCloudImage[]) event.getNewValue();
try {
- onCloudElementsChanged(cloud, newImages);
+ System.err.println("images updated");
+ replaceCloudElements(cloud, newImages);
} catch (DeltaCloudException e) {
// TODO: internationalize strings
ErrorUtils.handleError(
Modified: trunk/deltacloud/plugins/org.jboss.tools.deltacloud.ui/src/org/jboss/tools/deltacloud/ui/views/cloud/InstancesCategoryItem.java
===================================================================
--- trunk/deltacloud/plugins/org.jboss.tools.deltacloud.ui/src/org/jboss/tools/deltacloud/ui/views/cloud/InstancesCategoryItem.java 2011-01-06 13:08:56 UTC (rev 27943)
+++ trunk/deltacloud/plugins/org.jboss.tools.deltacloud.ui/src/org/jboss/tools/deltacloud/ui/views/cloud/InstancesCategoryItem.java 2011-01-06 14:07:35 UTC (rev 27944)
@@ -13,7 +13,6 @@
import java.beans.PropertyChangeEvent;
import java.text.MessageFormat;
-import org.eclipse.core.runtime.Assert;
import org.eclipse.core.runtime.IProgressMonitor;
import org.eclipse.core.runtime.IStatus;
import org.eclipse.core.runtime.Status;
@@ -53,7 +52,8 @@
@Override
protected IStatus doRun(IProgressMonitor monitor) throws DeltaCloudException {
try {
- getCloud().getInstances();
+ DeltaCloudInstance[] instances = getCloud().getInstances();
+ replaceCloudElements(getModel(), instances);
return Status.OK_STATUS;
} catch (DeltaCloudException e) {
clearChildren();
@@ -80,10 +80,10 @@
@Override
public void propertyChange(PropertyChangeEvent event) {
DeltaCloud cloud = (DeltaCloud) event.getSource();
- Assert.isTrue(cloud == getModel());
DeltaCloudInstance[] newInstances = (DeltaCloudInstance[]) event.getNewValue();
try {
- onCloudElementsChanged(cloud, newInstances);
+ System.err.println("images updated");
+ replaceCloudElements(cloud, newInstances);
} catch (DeltaCloudException e) {
// TODO: internationalize strings
ErrorUtils.handleError(
13 years, 5 months
JBoss Tools SVN: r27943 - trunk/vpe/tests/org.jboss.tools.vpe.spring.test/resources/SpringTest/src/main/webapp/WEB-INF/jsp.
by jbosstools-commits@lists.jboss.org
Author: mareshkau
Date: 2011-01-06 08:08:56 -0500 (Thu, 06 Jan 2011)
New Revision: 27943
Modified:
trunk/vpe/tests/org.jboss.tools.vpe.spring.test/resources/SpringTest/src/main/webapp/WEB-INF/jsp/hasBindErrors.jsp
trunk/vpe/tests/org.jboss.tools.vpe.spring.test/resources/SpringTest/src/main/webapp/WEB-INF/jsp/hasBindErrors.jsp.xml
Log:
https://issues.jboss.org/browse/JBIDE-8060
Modified: trunk/vpe/tests/org.jboss.tools.vpe.spring.test/resources/SpringTest/src/main/webapp/WEB-INF/jsp/hasBindErrors.jsp
===================================================================
--- trunk/vpe/tests/org.jboss.tools.vpe.spring.test/resources/SpringTest/src/main/webapp/WEB-INF/jsp/hasBindErrors.jsp 2011-01-06 10:10:10 UTC (rev 27942)
+++ trunk/vpe/tests/org.jboss.tools.vpe.spring.test/resources/SpringTest/src/main/webapp/WEB-INF/jsp/hasBindErrors.jsp 2011-01-06 13:08:56 UTC (rev 27943)
@@ -20,9 +20,7 @@
<h2>Errors for all bean fields</h2>
<div class="error">
<ul>
- <c:forEach var="error" items="${errors.allErrors}">
<li>${error.defaultMessage}</li>
- </c:forEach>
</ul>
</div>
</div>
@@ -36,9 +34,7 @@
<div class="error">
<ul>
<spring:bind path="formBean.user.*">
- <c:forEach var="error" items="${status.errorMessages}">
<li>${error}</li>
- </c:forEach>
</spring:bind>
</ul>
</div>
Modified: trunk/vpe/tests/org.jboss.tools.vpe.spring.test/resources/SpringTest/src/main/webapp/WEB-INF/jsp/hasBindErrors.jsp.xml
===================================================================
--- trunk/vpe/tests/org.jboss.tools.vpe.spring.test/resources/SpringTest/src/main/webapp/WEB-INF/jsp/hasBindErrors.jsp.xml 2011-01-06 10:10:10 UTC (rev 27942)
+++ trunk/vpe/tests/org.jboss.tools.vpe.spring.test/resources/SpringTest/src/main/webapp/WEB-INF/jsp/hasBindErrors.jsp.xml 2011-01-06 13:08:56 UTC (rev 27943)
@@ -1,68 +1,46 @@
<tests>
<test id="formBeanErrors">
- <DIV ID="formBeanErrors">
- <DIV STYLE="border: 1px solid red; width: 300px;">
- <H2>
+<DIV ID="formBeanErrors" STYLE="-moz-user-modify: read-write;">
+ <DIV
+ STYLE="border: 1px solid red; width: 300px; -moz-user-modify: read-write;">
+ <H2 STYLE="-moz-user-modify: read-write;">
+ <SPAN CLASS="vpe-text">
+ Errors for all bean fields
+ </SPAN>
+ </H2>
+ <DIV CLASS="error" STYLE="-moz-user-modify: read-write;">
+ <UL STYLE="-moz-user-modify: read-write;">
+ <LI STYLE="-moz-user-modify: read-write;">
<SPAN CLASS="vpe-text">
- Errors for all bean fields
+ ${error.defaultMessage}
</SPAN>
- </H2>
- <DIV CLASS="error">
- <UL>
- <SPAN CLASS="vpe-text">
- <LI>
- <SPAN CLASS="vpe-text">
- ${error.defaultMessage}
- </SPAN>
- </LI>
- <LI>
- <SPAN CLASS="vpe-text">
- ${error.defaultMessage}
- </SPAN>
- </LI>
- <LI>
- <SPAN CLASS="vpe-text">
- ${error.defaultMessage}
- </SPAN>
- </LI>
- </SPAN>
- </UL>
- </DIV>
- </DIV>
+ </LI>
+ </UL>
</DIV>
+ </DIV>
+</DIV>
</test>
<test id="userErrors">
- <DIV ID="userErrors">
- <DIV STYLE="border: 1px solid red; width: 300px;">
- <H2>
- <SPAN CLASS="vpe-text">
- Errors for all user fields only
- </SPAN>
- </H2>
- <DIV CLASS="error">
- <UL>
+<DIV ID="userErrors" STYLE="-moz-user-modify: read-write;">
+ <DIV
+ STYLE="border: 1px solid red; width: 300px; -moz-user-modify: read-write;">
+ <H2 STYLE="-moz-user-modify: read-write;">
+ <SPAN CLASS="vpe-text">
+ Errors for all user fields only
+ </SPAN>
+ </H2>
+ <DIV CLASS="error" STYLE="-moz-user-modify: read-write;">
+ <UL STYLE="-moz-user-modify: read-write;">
+ <SPAN CLASS="vpe-text" STYLE="-moz-user-modify: read-write;">
+ <LI STYLE="-moz-user-modify: read-write;">
<SPAN CLASS="vpe-text">
- <SPAN CLASS="vpe-text">
- <LI>
- <SPAN CLASS="vpe-text">
- ${error}
- </SPAN>
- </LI>
- <LI>
- <SPAN CLASS="vpe-text">
- ${error}
- </SPAN>
- </LI>
- <LI>
- <SPAN CLASS="vpe-text">
- ${error}
- </SPAN>
- </LI>
- </SPAN>
+ ${error}
</SPAN>
- </UL>
- </DIV>
- </DIV>
+ </LI>
+ </SPAN>
+ </UL>
</DIV>
+ </DIV>
+</DIV>
</test>
-</tests>
\ No newline at end of file
+</tests>
13 years, 5 months