Temporarily support 2020-1.M1 release train version
This commit is contained in:
@@ -172,6 +172,10 @@ public class ProjectVersion implements Comparable<ProjectVersion>, Serializable
|
||||
if (this.version == null) {
|
||||
throw new IllegalStateException("Version can't be null!");
|
||||
}
|
||||
if (this.version.equals("2020-1.M1")) {
|
||||
SplitVersion splitVersion = SplitVersion.dot(new String[] { "2020-1", "M1" });
|
||||
return splitVersion;
|
||||
}
|
||||
SplitVersion splitByHyphen = tryHyphenSeparatedVersion();
|
||||
if (splitByHyphen != null) {
|
||||
return splitByHyphen;
|
||||
|
||||
@@ -107,6 +107,7 @@ public class ProjectVersionTests {
|
||||
|
||||
@Test
|
||||
public void should_return_true_for_a_valid_version() {
|
||||
then(projectVersion("2020-1.M1").isValid()).isTrue();
|
||||
then(projectVersion("1.0.1.BUILD-SNAPSHOT").isValid()).isTrue();
|
||||
then(projectVersion("1.0.3.RC1").isValid()).isTrue();
|
||||
then(projectVersion("1.0.4.M1").isValid()).isTrue();
|
||||
|
||||
Reference in New Issue
Block a user