trim -release- from plugin version number when checking whether the runtime is outdated
This commit is contained in:
@@ -174,5 +174,5 @@ private val OUTDATED_RUNTIME_GROUP_DISPLAY_ID = "Outdated Kotlin Runtime"
|
||||
|
||||
fun isRuntimeOutdated(libraryVersion: String?, runtimeVersion: String): Boolean {
|
||||
return libraryVersion == null || libraryVersion.startsWith("internal-") != runtimeVersion.startsWith("internal-") ||
|
||||
VersionComparatorUtil.compare(runtimeVersion, libraryVersion) > 0
|
||||
VersionComparatorUtil.compare(runtimeVersion.substringBefore("-release-"), libraryVersion) > 0
|
||||
}
|
||||
|
||||
@@ -69,6 +69,8 @@ class KotlinRuntimeLibraryUtilTest : TestCase() {
|
||||
notOutdated("1.0.0-beta1-001-Idea3-1", "1.0.0-beta1-001")
|
||||
notOutdated("1.0.0-beta1-001-Idea3-(1)", "1.0.0-beta1-001")
|
||||
|
||||
notOutdated("1.0.0-release-IJ143-12", "1.0.0")
|
||||
|
||||
outdated("1.0.0-beta1-002-Idea141-1", "1.0.0-beta1-001")
|
||||
outdated("1.0.0-beta1-010-Idea141-1", "1.0.0-beta1-009")
|
||||
outdated("1.0.0-beta1-100-Idea141-1", "1.0.0-beta1-099")
|
||||
|
||||
Reference in New Issue
Block a user