Fix test bug in ZenDiscoveryIT.
This commit is contained in:
parent
f7ef600644
commit
1c858b57c4
|
@ -90,11 +90,13 @@ public class ZenDiscoveryIT extends ESIntegTestCase {
|
||||||
@Before
|
@Before
|
||||||
public void computePrevMajorVersion() {
|
public void computePrevMajorVersion() {
|
||||||
Version previousMajor;
|
Version previousMajor;
|
||||||
// find a GA build whose major version is N-1
|
// find a GA build whose major version is <N
|
||||||
do {
|
do {
|
||||||
previousMajor = VersionUtils.randomVersion(random());
|
previousMajor = VersionUtils.randomVersion(random());
|
||||||
} while (previousMajor.major != Version.CURRENT.major - 1
|
} while (previousMajor.onOrAfter(Version.CURRENT.minimumCompatibilityVersion())
|
||||||
&& (previousMajor.isAlpha() || previousMajor.isBeta() || previousMajor.isRC()));
|
|| previousMajor.isAlpha()
|
||||||
|
|| previousMajor.isBeta()
|
||||||
|
|| previousMajor.isRC());
|
||||||
previousMajorVersion = previousMajor;
|
previousMajorVersion = previousMajor;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue