mirror of
https://github.com/scm-manager/scm-manager.git
synced 2025-11-10 15:35:49 +01:00
fix bug with min-version condition
This commit is contained in:
@@ -142,7 +142,8 @@ public class PluginCondition
|
||||
|
||||
if (Util.isNotEmpty(minVersion) && Util.isNotEmpty(version))
|
||||
{
|
||||
supported = new PluginVersion(version).isNewer(minVersion);
|
||||
supported = (minVersion.equalsIgnoreCase(version)
|
||||
|| new PluginVersion(version).isNewer(minVersion));
|
||||
}
|
||||
|
||||
if (supported && Util.isNotEmpty(this.os) && Util.isNotEmpty(os))
|
||||
|
||||
@@ -102,5 +102,7 @@ public class PluginConditionTest
|
||||
assertTrue(new PluginCondition("1.0", null,
|
||||
null).isSupported("1.1-SNAPSHOT", null,
|
||||
null));
|
||||
assertTrue(new PluginCondition("1.1", null, null).isSupported("1.1", null,
|
||||
null));
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user