[TEST] Add test that ensures we never bump the minor version of lucene in a bugfix release
This commit is contained in:
parent
2390eb5ed4
commit
52c283cdee
|
@ -260,4 +260,20 @@ public class VersionTests extends ESTestCase {
|
|||
}
|
||||
}
|
||||
|
||||
// this test ensures we never bump the lucene version in a bugfix release
|
||||
public void testLuceneVersionIsSameOnMinorRelease() {
|
||||
for (Version version : VersionUtils.allVersions()) {
|
||||
for (Version other : VersionUtils.allVersions()) {
|
||||
if (other.onOrAfter(version)) {
|
||||
assertTrue("lucene versions must be " + other + " >= " + version,
|
||||
other.luceneVersion.onOrAfter(version.luceneVersion));
|
||||
}
|
||||
if (other.major == version.major && other.minor == version.minor) {
|
||||
assertEquals(other.luceneVersion.major, version.luceneVersion.major);
|
||||
assertEquals(other.luceneVersion.minor, version.luceneVersion.minor);
|
||||
// should we also assert the lucene bugfix version?
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue