Author: dazarov
Date: 2010-08-05 13:08:43 -0400 (Thu, 05 Aug 2010)
New Revision: 23946
Added:
trunk/jst/tests/org.jboss.tools.jst.web.kb.test/projects/TestKbModel/WebContent/WEB-INF/lib/jboss-seam-pdf.jar
Modified:
trunk/jst/tests/org.jboss.tools.jst.web.kb.test/src/org/jboss/tools/jst/web/kb/test/WebKbTest.java
Log:
https://jira.jboss.org/browse/JBIDE-5231
Added:
trunk/jst/tests/org.jboss.tools.jst.web.kb.test/projects/TestKbModel/WebContent/WEB-INF/lib/jboss-seam-pdf.jar
===================================================================
(Binary files differ)
Property changes on:
trunk/jst/tests/org.jboss.tools.jst.web.kb.test/projects/TestKbModel/WebContent/WEB-INF/lib/jboss-seam-pdf.jar
___________________________________________________________________
Name: svn:mime-type
+ application/octet-stream
Modified:
trunk/jst/tests/org.jboss.tools.jst.web.kb.test/src/org/jboss/tools/jst/web/kb/test/WebKbTest.java
===================================================================
---
trunk/jst/tests/org.jboss.tools.jst.web.kb.test/src/org/jboss/tools/jst/web/kb/test/WebKbTest.java 2010-08-05
16:59:58 UTC (rev 23945)
+++
trunk/jst/tests/org.jboss.tools.jst.web.kb.test/src/org/jboss/tools/jst/web/kb/test/WebKbTest.java 2010-08-05
17:08:43 UTC (rev 23946)
@@ -79,6 +79,30 @@
fail("Can't find <f:facet name=\"\"> proposal.");
}
+ /**
+ *
https://jira.jboss.org/jira/browse/JBIDE-5231
+ */
+ public void testSeamPdf() {
+ IFile file = testProject.getFile("WebContent/pages/testSeamPdfAndMail.jsp");
+ ELContext context = PageContextFactory.createPageContext(file);
+ KbQuery query = new KbQuery();
+ query.setMask(true);
+ query.setOffset(315);
+ query.setType(Type.ATTRIBUTE_NAME);
+ query.setParentTags(new String[]{"p:document"});
+ query.setPrefix("p");
+
query.setUri("http://jboss.com/products/seam/pdf");
+ query.setValue("ori");
+
+ TextProposal[] proposals = PageProcessor.getInstance().getProposals(query, context);
+ for (TextProposal proposal : proposals) {
+ if("orientation".equals(proposal.getReplacementString())) {
+ return;
+ }
+ }
+ fail("Can't find <p:document orientation=\"\">
proposal.");
+ }
+
public void testCustomExtensions() {
CustomTagLibAttribute[] attributes =
CustomTagLibManager.getInstance().getComponentExtensions();
assertNotNull("Can't load component extensions.", attributes);