From: Simon Brandhof Date: Fri, 17 Aug 2012 13:33:36 +0000 (+0200) Subject: SONAR-3741 The plugin upgrades that are available in Update Center are not compatible... X-Git-Tag: 3.3~335 X-Git-Url: https://source.dussan.org/?a=commitdiff_plain;h=ffde32687741fcf5c853becc833c849669988827;p=sonarqube.git SONAR-3741 The plugin upgrades that are available in Update Center are not compatible with Sonar Release Candidates --- diff --git a/sonar-core/src/main/java/org/sonar/core/plugins/DefaultPluginMetadata.java b/sonar-core/src/main/java/org/sonar/core/plugins/DefaultPluginMetadata.java index 6b96809a76b..c0c00ae9be3 100644 --- a/sonar-core/src/main/java/org/sonar/core/plugins/DefaultPluginMetadata.java +++ b/sonar-core/src/main/java/org/sonar/core/plugins/DefaultPluginMetadata.java @@ -191,8 +191,8 @@ public class DefaultPluginMetadata implements PluginMetadata, Comparable= 0; } diff --git a/sonar-core/src/test/java/org/sonar/core/plugins/DefaultPluginMetadataTest.java b/sonar-core/src/test/java/org/sonar/core/plugins/DefaultPluginMetadataTest.java index 7d8a770e85e..0714f5bdf23 100644 --- a/sonar-core/src/test/java/org/sonar/core/plugins/DefaultPluginMetadataTest.java +++ b/sonar-core/src/test/java/org/sonar/core/plugins/DefaultPluginMetadataTest.java @@ -113,6 +113,9 @@ public class DefaultPluginMetadataTest { assertThat(pluginWithVersion("1.0").isCompatibleWith("1.1")).isTrue(); assertThat(pluginWithVersion("1.1.1").isCompatibleWith("1.1.2")).isTrue(); assertThat(pluginWithVersion("2.0").isCompatibleWith("2.1.0")).isTrue(); + assertThat(pluginWithVersion("3.2").isCompatibleWith("3.2-RC1")).isTrue(); + assertThat(pluginWithVersion("3.2").isCompatibleWith("3.2-RC2")).isTrue(); + assertThat(pluginWithVersion("3.2").isCompatibleWith("3.1-RC2")).isFalse(); assertThat(pluginWithVersion("1.1").isCompatibleWith("1.0")).isFalse(); assertThat(pluginWithVersion("2.0.1").isCompatibleWith("2.0.0")).isFalse(); @@ -127,7 +130,6 @@ public class DefaultPluginMetadataTest { assertThat(pluginWithVersion("3.1-RC2").isCompatibleWith("3.2-SNAPSHOT")).isTrue(); assertThat(pluginWithVersion("3.1-RC1").isCompatibleWith("3.2-RC2")).isTrue(); assertThat(pluginWithVersion("3.1-RC1").isCompatibleWith("3.1-RC2")).isTrue(); - assertThat(pluginWithVersion("3.1-RC2").isCompatibleWith("3.1-RC1")).isFalse(); assertThat(pluginWithVersion(null).isCompatibleWith("0")).isTrue(); assertThat(pluginWithVersion(null).isCompatibleWith("3.1")).isTrue();