Author: vrubezhny
Date: 2009-10-23 22:43:02 -0400 (Fri, 23 Oct 2009)
New Revision: 18281
Modified:
branches/jbosstools-3.1.0.M4/jst/tests/org.jboss.tools.jst.jsp.test/src/org/jboss/tools/jst/jsp/test/ca/ContentAssistantTestCase.java
Log:
JBIDE-5059: Fix JstJspAllTests.testJsfJspJbide2016Test
JBIDE-5060: Fix JstJspAllTests.testCAForELinStyleTest
The test cases are fixed in 3.1.0.M4 branch
Modified:
branches/jbosstools-3.1.0.M4/jst/tests/org.jboss.tools.jst.jsp.test/src/org/jboss/tools/jst/jsp/test/ca/ContentAssistantTestCase.java
===================================================================
---
branches/jbosstools-3.1.0.M4/jst/tests/org.jboss.tools.jst.jsp.test/src/org/jboss/tools/jst/jsp/test/ca/ContentAssistantTestCase.java 2009-10-24
02:33:13 UTC (rev 18280)
+++
branches/jbosstools-3.1.0.M4/jst/tests/org.jboss.tools.jst.jsp.test/src/org/jboss/tools/jst/jsp/test/ca/ContentAssistantTestCase.java 2009-10-24
02:43:02 UTC (rev 18281)
@@ -15,6 +15,7 @@
import org.eclipse.ui.part.FileEditorInput;
import org.eclipse.wst.sse.core.internal.provisional.text.IStructuredDocument;
import org.eclipse.wst.sse.ui.internal.StructuredTextViewer;
+import org.jboss.tools.jst.jsp.contentassist.AutoContentAssistantProposal;
import org.jboss.tools.jst.jsp.jspeditor.JSPMultiPageEditor;
import org.jboss.tools.jst.jsp.jspeditor.JSPTextEditor;
import org.jboss.tools.jst.jsp.test.TestUtil;
@@ -94,7 +95,12 @@
protected boolean compareProposal(String proposalName, ICompletionProposal[]
proposals){
for (int i = 0; i < proposals.length; i++) {
- if(proposals[i].getDisplayString().toLowerCase().equals(proposalName.toLowerCase()))
return true;
+ if (proposals[i] instanceof AutoContentAssistantProposal) {
+ AutoContentAssistantProposal ap = (AutoContentAssistantProposal)proposals[i];
+ if (ap.getReplacementString().toLowerCase().equals(proposalName.toLowerCase()))
return true;
+ } else {
+ if(proposals[i].getDisplayString().toLowerCase().equals(proposalName.toLowerCase()))
return true;
+ }
}
return false;
}
Show replies by date