Merge pull request #842 from nosqlbench/nosqlbench-841-hashedrange

nosqlbench-841-hashedrange
This commit is contained in:
Jonathan Shook 2022-12-09 17:23:09 -06:00 committed by GitHub
commit 21bc389f21
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 2 additions and 2 deletions

View File

@ -36,7 +36,7 @@ public class HashedRangeToLongList implements LongFunction<List<Long>> {
private final HashRange sizeRange;
public HashedRangeToLongList(int minVal, int maxVal, int minSize, int maxSize) {
if (minSize>=maxSize || minSize>=maxSize) {
if (minSize>maxSize || minVal>maxVal) {
throw new RuntimeException("HashedRangeToLongList must have minval, maxval, minsize, maxsize, where min<max.");
}
this.valueRange = new HashRange(minVal,maxVal);

View File

@ -29,7 +29,7 @@ public class HashedRangeToLongListTest {
public void longListRangeTest() {
HashedRangeToLongList gener = new HashedRangeToLongList(3, 6, 9, 12);
for (int i = 0; i < 100; i++) {
System.out.println("long list range test size: " + i);
// System.out.println("long list range test size: " + i);
List<Long> list= gener.apply(i);
assertThat(list.size()).isBetween(9,12);
for (Long longVal : list) {