Minor, drop unused DiagnosedRange#file

This commit is contained in:
Alexander Udalov
2016-12-20 12:17:29 +03:00
parent 0e11615780
commit 7146a6db74
3 changed files with 0 additions and 16 deletions
@@ -732,7 +732,6 @@ public class CheckerTestUtil {
private final int start;
private int end;
private final List<TextDiagnostic> diagnostics = ContainerUtil.newSmartList();
private PsiFile file;
protected DiagnosedRange(int start) {
this.start = start;
@@ -757,14 +756,5 @@ public class CheckerTestUtil {
public void addDiagnostic(String diagnostic) {
diagnostics.add(TextDiagnostic.parseDiagnostic(diagnostic));
}
public void setFile(@NotNull PsiFile file) {
this.file = file;
}
@NotNull
public PsiFile getFile() {
return file;
}
}
}
@@ -150,9 +150,6 @@ abstract class BaseDiagnosticsTest : KotlinMultiFileTestWithJava<TestModule, Tes
this.expectedText = textWithMarkers
this.clearText = CheckerTestUtil.parseDiagnosedRanges(addExtras(expectedText), diagnosedRanges)
this.ktFile = TestCheckerUtil.createCheckAndReturnPsiFile(fileName, clearText, project)
for (diagnosedRange in diagnosedRanges) {
diagnosedRange.file = ktFile
}
}
}
@@ -153,9 +153,6 @@ public class CheckerTestUtilTest extends KotlinTestWithEnvironment {
List<DiagnosedRange> diagnosedRanges = Lists.newArrayList();
CheckerTestUtil.parseDiagnosedRanges(expectedText, diagnosedRanges);
for (DiagnosedRange diagnosedRange : diagnosedRanges) {
diagnosedRange.setFile(psiFile);
}
List<Diagnostic> diagnostics = CheckerTestUtil.getDiagnosticsIncludingSyntaxErrors(bindingContext, psiFile, false, null);
Collections.sort(diagnostics, CheckerTestUtil.DIAGNOSTIC_COMPARATOR);