Author: scabanovich
Date: 2011-11-03 18:36:58 -0400 (Thu, 03 Nov 2011)
New Revision: 36165
Added:
trunk/jst/tests/org.jboss.tools.jst.web.kb.test/projects/utility/src/META-INF/resources/
trunk/jst/tests/org.jboss.tools.jst.web.kb.test/projects/utility/src/META-INF/resources/cc/
trunk/jst/tests/org.jboss.tools.jst.web.kb.test/projects/utility/src/META-INF/resources/cc/inputText.xhtml
Modified:
trunk/jst/tests/org.jboss.tools.jst.web.kb.test/src/org/jboss/tools/jst/web/kb/test/WebWithModuleTest.java
Log:
JBIDE-10103
https://issues.jboss.org/browse/JBIDE-10103
Loaded composite components from Java source folders.
Added:
trunk/jst/tests/org.jboss.tools.jst.web.kb.test/projects/utility/src/META-INF/resources/cc/inputText.xhtml
===================================================================
---
trunk/jst/tests/org.jboss.tools.jst.web.kb.test/projects/utility/src/META-INF/resources/cc/inputText.xhtml
(rev 0)
+++
trunk/jst/tests/org.jboss.tools.jst.web.kb.test/projects/utility/src/META-INF/resources/cc/inputText.xhtml 2011-11-03
22:36:58 UTC (rev 36165)
@@ -0,0 +1,24 @@
+<!DOCTYPE composition PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
+ "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<ui:composition
xmlns="http://www.w3.org/1999/xhtml"
+
xmlns:ui="http://java.sun.com/jsf/facelets"
+
xmlns:f="http://java.sun.com/jsf/core"
+
xmlns:h="http://java.sun.com/jsf/html"
+
xmlns:c="http://java.sun.com/jsp/jstl/core"
+
xmlns:cc="http://java.sun.com/jsf/composite"
+ xmlns:t="http://br.com.test/ui/components">
+
+ <cc:interface componentType="br.com.test.ui.inputtext">
+ <cc:attribute name="label" required="true"/>
+ <cc:attribute name="value" />
+ <cc:attribute name="action" />
+ </cc:interface>
+
+ <cc:implementation>
+ <div class="testinputtext" id="#{cc.clientId}">
+ <h:outputLabel id="label" value="#{cc.attrs.label}: "
for="#{cc.clientId}:input" />
+ <h:inputText
onkeypress="showUndoButton('#{cc.clientId}:testsoftbutton');"
id="input" binding="#{cc.input}" value="#{cc.attrs.value}"
/>
+ <t:button id="testsoftbutton" alt="lero"
styleClass="testbutton" value="undo"
action="#{cc.actionUndoValue}" />
+ </div>
+ </cc:implementation>
+</ui:composition>
\ No newline at end of file
Modified:
trunk/jst/tests/org.jboss.tools.jst.web.kb.test/src/org/jboss/tools/jst/web/kb/test/WebWithModuleTest.java
===================================================================
---
trunk/jst/tests/org.jboss.tools.jst.web.kb.test/src/org/jboss/tools/jst/web/kb/test/WebWithModuleTest.java 2011-11-03
22:36:10 UTC (rev 36164)
+++
trunk/jst/tests/org.jboss.tools.jst.web.kb.test/src/org/jboss/tools/jst/web/kb/test/WebWithModuleTest.java 2011-11-03
22:36:58 UTC (rev 36165)
@@ -51,9 +51,22 @@
*/
public void testWebProject() throws CoreException {
assertTrue("true".equals(utility.getPersistentProperty(KbProjectFactory.NATURE_MOCK)));
+
+ IKbProject kbUtility = KbProjectFactory.getKbProject(utility, true);
+ assertNotNull(kbUtility);
+ int w = 0;
+ while(kbUtility.getTagLibraries().length == 0 && w++ < 50) {
+ try {
+ Thread.sleep(1000);
+ System.out.println("waiting for utility");
+ } catch (InterruptedException e) {
+ break;
+ }
+ }
IKbProject kb = KbProjectFactory.getKbProject(webapp, true);
ITagLibrary[] ls = kb.getTagLibraries("utility-lib");
assertTrue(ls.length > 0);
}
+
}