File tree Expand file tree Collapse file tree 2 files changed +1
-9
lines changed
ide-common/src/main/java/org/digma/intellij/plugin/index
java/src/main/java/org/digma/intellij/plugin/idea/psi/java Expand file tree Collapse file tree 2 files changed +1
-9
lines changed Original file line number Diff line number Diff line change @@ -92,11 +92,10 @@ public boolean acceptInput(@NotNull VirtualFile file) {
9292 // reference to the project.
9393 if (DocumentInfoIndex .this .project != null && !DocumentInfoIndex .this .project .isDisposed ()) {
9494 boolean isInSourceContent = ProjectFileIndex .getInstance (project ).isInSourceContent (file );
95- boolean isInTestSourceContent = ProjectFileIndex .getInstance (project ).isInTestSourceContent (file );
9695 boolean isExcluded = ProjectFileIndex .getInstance (project ).isExcluded (file );
9796 boolean hasModule = ProjectFileIndex .getInstance (project ).getModuleForFile (file ) != null ;
9897
99- return hasModule && isInSourceContent && !isInTestSourceContent && ! isExcluded ;
98+ return hasModule && isInSourceContent && !isExcluded ;
10099
101100 } else {
102101 //LanguageService.isInSourceContent will call JavaFileElementType.isInSourceContent for java files
Original file line number Diff line number Diff line change @@ -321,7 +321,6 @@ private boolean isRelevantFile(PsiFile psiFile) {
321321 return psiFile .isWritable () &&
322322 isSupportedFile (project , psiFile ) &&
323323 !ProjectFileIndex .getInstance (project ).isInLibrary (psiFile .getVirtualFile ()) &&
324- !ProjectFileIndex .getInstance (project ).isInTestSourceContent (psiFile .getVirtualFile ()) &&
325324 !DocumentInfoIndex .namesToExclude .contains (psiFile .getVirtualFile ().getName ());
326325 }
327326
@@ -337,12 +336,6 @@ public boolean isIndexedLanguage() {
337336 String fileUri = PsiUtils .psiFileToUri (psiFile );
338337 Map <String , MethodInfo > methodInfoMap = new HashMap <>();
339338
340-
341- //currently we build an empty index for test sources, there is no easy way to exclude them from indexing
342- if (ProjectFileIndex .getInstance (project ).isInTestSourceContent (psiFile .getVirtualFile ())) {
343- return new DocumentInfo (fileUri , methodInfoMap );
344- }
345-
346339 //it must be a PsiJavaFile so casting should be ok
347340 PsiJavaFile psiJavaFile = (PsiJavaFile ) psiFile ;
348341
You can’t perform that action at this time.
0 commit comments