add setMaxTableFilesSize Options unit test
This commit is contained in:
parent
d62b6ed838
commit
dda74111ae
@ -723,4 +723,23 @@ public class ColumnFamilyOptionsTest {
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@Test
|
||||
public void maxTableFilesSizeFIFO() {
|
||||
ColumnFamilyOptions opt = null;
|
||||
try {
|
||||
opt = new ColumnFamilyOptions();
|
||||
long longValue = rand.nextLong();
|
||||
// Size has to be positive
|
||||
longValue = (longValue < 0) ? -longValue : longValue;
|
||||
longValue = (longValue == 0) ? longValue + 1 : longValue;
|
||||
opt.setMaxTableFilesSizeFIFO(longValue);
|
||||
assertThat(opt.maxTableFilesSizeFIFO()).
|
||||
isEqualTo(longValue);
|
||||
} finally {
|
||||
if (opt != null) {
|
||||
opt.dispose();
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -1108,6 +1108,25 @@ public class OptionsTest {
|
||||
}
|
||||
}
|
||||
|
||||
@Test
|
||||
public void maxTableFilesSizeFIFO() {
|
||||
Options opt = null;
|
||||
try {
|
||||
opt = new Options();
|
||||
long longValue = rand.nextLong();
|
||||
// Size has to be positive
|
||||
longValue = (longValue < 0) ? -longValue : longValue;
|
||||
longValue = (longValue == 0) ? longValue + 1 : longValue;
|
||||
opt.setMaxTableFilesSizeFIFO(longValue);
|
||||
assertThat(opt.maxTableFilesSizeFIFO()).
|
||||
isEqualTo(longValue);
|
||||
} finally {
|
||||
if (opt != null) {
|
||||
opt.dispose();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@Test
|
||||
public void rateLimiterConfig() {
|
||||
Options options = null;
|
||||
|
Loading…
Reference in New Issue
Block a user