aboutsummaryrefslogtreecommitdiffstats
path: root/enforcer-rule
diff options
context:
space:
mode:
authorJulien Eluard <[email protected]>2011-02-09 19:49:17 -0800
committerJulien Eluard <[email protected]>2011-02-09 19:49:17 -0800
commitb4210fff004f747704bbd9b230a00e60faa4f30e (patch)
tree0a1b6ba7bebbd63ff6366b0088fe477ebea39f98 /enforcer-rule
parentad2a2c0b387218f885fd52678a5461660e53d87c (diff)
Wrong check on compatibility types.
Diffstat (limited to 'enforcer-rule')
-rwxr-xr-xenforcer-rule/src/main/java/org/semver/enforcer/RequireBackwardCompatibility.java2
1 files changed, 1 insertions, 1 deletions
diff --git a/enforcer-rule/src/main/java/org/semver/enforcer/RequireBackwardCompatibility.java b/enforcer-rule/src/main/java/org/semver/enforcer/RequireBackwardCompatibility.java
index 57050f7..e601515 100755
--- a/enforcer-rule/src/main/java/org/semver/enforcer/RequireBackwardCompatibility.java
+++ b/enforcer-rule/src/main/java/org/semver/enforcer/RequireBackwardCompatibility.java
@@ -53,7 +53,7 @@ public final class RequireBackwardCompatibility extends AbstractEnforcerRule {
}
final Delta.CompatibilityType detectedCompatibilityType = delta.computeCompatibilityType();
- if (detectedCompatibilityType != expectedCompatibilityType) {
+ if (detectedCompatibilityType.compareTo(expectedCompatibilityType) > 0) {
fail(delta, "Current codebase is not backward compatible ("+this.compatibilityType+") with version <"+previous+">. Compatibility type has been detected as <"+detectedCompatibilityType+">");
}
}