KT-64205 [AA] Add shortening with default settings to the testData

This commit is contained in:
Roman Golyshev
2023-12-13 19:30:57 +02:00
committed by teamcity
parent 146d93a044
commit d5896f20f0
174 changed files with 336 additions and 23 deletions
@@ -20,15 +20,19 @@ abstract class AbstractReferenceShortenerForWholeFileTest : AbstractAnalysisApiB
val shortenings = executeOnPooledThreadInReadAction {
analyseForTest(file) {
ShortenStrategy.entries.associateWith { option ->
val shorteningsForOption = collectPossibleReferenceShortenings(
file,
file.textRange,
classShortenStrategy = { option },
callableShortenStrategy = { option }
)
buildMap {
this += "default settings" to collectPossibleReferenceShortenings(file, file.textRange)
shorteningsForOption
this += ShortenStrategy.entries.associateWith { option ->
val shorteningsForOption = collectPossibleReferenceShortenings(
file,
file.textRange,
classShortenStrategy = { option },
callableShortenStrategy = { option }
)
shorteningsForOption
}
}
}
}
@@ -29,15 +29,19 @@ abstract class AbstractReferenceShortenerTest : AbstractAnalysisApiBasedSingleMo
val shortenings = executeOnPooledThreadInReadAction {
analyseForTest(element) {
ShortenStrategy.entries.associateWith { option ->
val shorteningsForOption = collectPossibleReferenceShorteningsInElement(
element,
shortenOptions = ShortenOptions.ALL_ENABLED,
classShortenStrategy = { option },
callableShortenStrategy = { option }
)
buildMap {
this += "default settings" to collectPossibleReferenceShorteningsInElement(element)
shorteningsForOption
this += ShortenStrategy.entries.associate { option ->
val shorteningsForOption = collectPossibleReferenceShorteningsInElement(
element,
shortenOptions = ShortenOptions.ALL_ENABLED,
classShortenStrategy = { option },
callableShortenStrategy = { option }
)
option.toString() to shorteningsForOption
}
}
}
}