boolean (UnusedDeclarationInspectionBase tool, RefElement refElement) { if (tool.isTestEntryPoints()) return true; final PsiElement element = refElement.getPsiElement(); final VirtualFile file = PsiUtilCore.getVirtualFile(element); return file != null && !ProjectRootManager.getInstance(element.getProject()).getFileIndex().isInTestSourceContent(file); }