[TEST] fix test to only enforce settings if it's not negative AND less than the limit

This commit is contained in:
Simon Willnauer 2016-02-22 10:50:00 -08:00
parent 35ae8263af
commit a574baaf3e
1 changed files with 1 additions and 1 deletions

View File

@ -43,7 +43,7 @@ public class BootstrapSettingsTests extends ESTestCase {
long maxFileDescriptorCount = ProcessProbe.getInstance().getMaxFileDescriptorCount();
try {
Bootstrap.enforceOrLogLimits(build);
if (maxFileDescriptorCount != -1 || maxFileDescriptorCount < (1 << 16)) {
if (maxFileDescriptorCount != -1 && maxFileDescriptorCount < (1 << 16)) {
fail("must have enforced limits: " + maxFileDescriptorCount);
}
} catch (IllegalStateException ex) {