Author: scabanovich
Date: 2012-01-06 14:24:35 -0500 (Fri, 06 Jan 2012)
New Revision: 37691
Modified:
trunk/cdi/tests/org.jboss.tools.cdi.ui.test/src/org/jboss/tools/cdi/ui/test/search/CDISearchParticipantTest.java
trunk/cdi/tests/org.jboss.tools.cdi.ui.test/src/org/jboss/tools/cdi/ui/test/search/FiveDependentProjectsSearchParticipantTest.java
Log:
JBIDE-10601
https://issues.joss.org/browse/JBIDE-10601
Method EclipseUtil.getCompilationUnit(IFile) should return existing Java element or null.
Modified:
trunk/cdi/tests/org.jboss.tools.cdi.ui.test/src/org/jboss/tools/cdi/ui/test/search/CDISearchParticipantTest.java
===================================================================
---
trunk/cdi/tests/org.jboss.tools.cdi.ui.test/src/org/jboss/tools/cdi/ui/test/search/CDISearchParticipantTest.java 2012-01-06
19:21:36 UTC (rev 37690)
+++
trunk/cdi/tests/org.jboss.tools.cdi.ui.test/src/org/jboss/tools/cdi/ui/test/search/CDISearchParticipantTest.java 2012-01-06
19:24:35 UTC (rev 37691)
@@ -43,6 +43,9 @@
assertNotNull("File - "+fileName+" not found", file);
try{
ICompilationUnit compilationUnit = EclipseUtil.getCompilationUnit(file);
+
+ assertNotNull("CompilationUnit not found", compilationUnit);
+
IJavaElement element = null;
IType type = compilationUnit.findPrimaryType();
Modified:
trunk/cdi/tests/org.jboss.tools.cdi.ui.test/src/org/jboss/tools/cdi/ui/test/search/FiveDependentProjectsSearchParticipantTest.java
===================================================================
---
trunk/cdi/tests/org.jboss.tools.cdi.ui.test/src/org/jboss/tools/cdi/ui/test/search/FiveDependentProjectsSearchParticipantTest.java 2012-01-06
19:21:36 UTC (rev 37690)
+++
trunk/cdi/tests/org.jboss.tools.cdi.ui.test/src/org/jboss/tools/cdi/ui/test/search/FiveDependentProjectsSearchParticipantTest.java 2012-01-06
19:24:35 UTC (rev 37691)
@@ -64,6 +64,9 @@
assertNotNull("File - "+fileName+" not found", file);
try{
ICompilationUnit compilationUnit = EclipseUtil.getCompilationUnit(file);
+
+ assertNotNull("CompilationUnit not found", compilationUnit);
+
IJavaElement element = null;
IType type = compilationUnit.findPrimaryType();