[AA] Mute tests related to decompilation of aliased types from stubs
#KT-58786
This commit is contained in:
committed by
Space Team
parent
8f447e5b78
commit
47b8fd7e0c
+27
@@ -22,6 +22,7 @@ abstract class AbstractDiagnosticCompilerTestDataTest : AbstractCompilerBasedTes
|
|||||||
override fun TestConfigurationBuilder.configureTest() {
|
override fun TestConfigurationBuilder.configureTest() {
|
||||||
baseFirDiagnosticTestConfiguration(frontendFacade = ::LowLevelFirFrontendFacade.bind(LLFirAnalyzerFacadeFactoryWithoutPreresolve))
|
baseFirDiagnosticTestConfiguration(frontendFacade = ::LowLevelFirFrontendFacade.bind(LLFirAnalyzerFacadeFactoryWithoutPreresolve))
|
||||||
useAfterAnalysisCheckers(::ContractViolationSuppressor)
|
useAfterAnalysisCheckers(::ContractViolationSuppressor)
|
||||||
|
useAfterAnalysisCheckers(::DiagnosticSuppressor)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -51,3 +52,29 @@ private class ContractViolationSuppressor(testServices: TestServices) : AfterAna
|
|||||||
val IGNORE_CONTRACT_VIOLATIONS by directive("Temporary disables test with contract violation until the issue is fixed")
|
val IGNORE_CONTRACT_VIOLATIONS by directive("Temporary disables test with contract violation until the issue is fixed")
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
private class DiagnosticSuppressor(testServices: TestServices) : AfterAnalysisChecker(testServices) {
|
||||||
|
override val directiveContainers: List<DirectivesContainer> get() = listOf(Companion)
|
||||||
|
|
||||||
|
override fun suppressIfNeeded(failedAssertions: List<WrappedException>): List<WrappedException> {
|
||||||
|
if (!isDisabled()) {
|
||||||
|
return failedAssertions
|
||||||
|
}
|
||||||
|
|
||||||
|
return if (failedAssertions.isEmpty()) {
|
||||||
|
listOf(
|
||||||
|
AssertionError(
|
||||||
|
"Test contains $IGNORE_DIAGNOSTIC_API directive but no errors was reported. Please remove directive",
|
||||||
|
).wrap()
|
||||||
|
)
|
||||||
|
} else {
|
||||||
|
emptyList()
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
private fun isDisabled(): Boolean = IGNORE_DIAGNOSTIC_API in testServices.moduleStructure.allDirectives
|
||||||
|
|
||||||
|
companion object : SimpleDirectivesContainer() {
|
||||||
|
val IGNORE_DIAGNOSTIC_API by directive("Temporary disables diagnostic api test until the issue is fixed")
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|||||||
@@ -1,3 +1,7 @@
|
|||||||
|
// IGNORE_DIAGNOSTIC_API
|
||||||
|
// IGNORE_REVERSED_RESOLVE
|
||||||
|
// Ignore reason: KT-58786
|
||||||
|
|
||||||
interface Diagnostic {
|
interface Diagnostic {
|
||||||
val name: String
|
val name: String
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user