public class TestFinderHelper
extends java.lang.Object
Constructor and Description |
---|
TestFinderHelper() |
Modifier and Type | Method and Description |
---|---|
static java.lang.Integer |
calcTestNameProximity(java.lang.String className,
java.lang.String testName) |
static java.util.List<Pair<java.lang.String,java.lang.Integer>> |
collectPossibleClassNamesWithWeights(java.lang.String testName) |
static java.util.Collection<PsiElement> |
findClassesForTest(PsiElement element) |
static PsiElement |
findSourceElement(PsiElement from) |
static java.util.Collection<PsiElement> |
findTestsForClass(PsiElement element) |
static java.util.List<TestFinder> |
getFinders() |
static java.util.List<PsiElement> |
getSortedElements(java.util.List<? extends Pair<? extends PsiNamedElement,java.lang.Integer>> elementsWithWeights,
boolean weightsAscending) |
static java.util.List<PsiElement> |
getSortedElements(java.util.List<? extends Pair<? extends PsiNamedElement,java.lang.Integer>> elementsWithWeights,
boolean weightsAscending,
java.util.Comparator<? super PsiElement> sameNameComparator) |
static boolean |
isTest(PsiElement element) |
public static PsiElement findSourceElement(PsiElement from)
public static java.util.Collection<PsiElement> findTestsForClass(PsiElement element)
public static java.util.Collection<PsiElement> findClassesForTest(PsiElement element)
public static boolean isTest(PsiElement element)
public static java.util.List<TestFinder> getFinders()
public static java.lang.Integer calcTestNameProximity(java.lang.String className, java.lang.String testName)
public static java.util.List<PsiElement> getSortedElements(java.util.List<? extends Pair<? extends PsiNamedElement,java.lang.Integer>> elementsWithWeights, boolean weightsAscending)
public static java.util.List<PsiElement> getSortedElements(java.util.List<? extends Pair<? extends PsiNamedElement,java.lang.Integer>> elementsWithWeights, boolean weightsAscending, java.util.Comparator<? super PsiElement> sameNameComparator)
public static java.util.List<Pair<java.lang.String,java.lang.Integer>> collectPossibleClassNamesWithWeights(java.lang.String testName)