[FIR IDE] Compare error types consistently in test data
Use the fixed error type description so test data can be shared across both frontends.
This commit is contained in:
+3
-1
@@ -8,6 +8,7 @@ package org.jetbrains.kotlin.analysis.api.impl.base.test.components
|
||||
import org.jetbrains.kotlin.analysis.api.impl.barebone.test.FrontendApiTestConfiguratorService
|
||||
import org.jetbrains.kotlin.analysis.api.impl.barebone.test.expressionMarkerProvider
|
||||
import org.jetbrains.kotlin.analysis.api.impl.base.test.test.framework.AbstractHLApiSingleFileTest
|
||||
import org.jetbrains.kotlin.analysis.api.symbols.DebugSymbolRenderer
|
||||
import org.jetbrains.kotlin.psi.KtExpression
|
||||
import org.jetbrains.kotlin.psi.KtFile
|
||||
import org.jetbrains.kotlin.test.model.TestModule
|
||||
@@ -24,7 +25,8 @@ abstract class AbstractExpectedExpressionTypeTest(
|
||||
|
||||
val actualExpectedTypeText: String? = executeOnPooledThreadInReadAction {
|
||||
analyseForTest(expressionAtCaret) {
|
||||
expressionAtCaret.getExpectedType()?.asStringForDebugging()
|
||||
val expectedType = expressionAtCaret.getExpectedType() ?: return@analyseForTest null
|
||||
DebugSymbolRenderer.renderType(expectedType)
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user