}
@Test
public void testSearchNoSplitRoaring()
{
BitmapFactory bf = new RoaringBitmapFactory();
RTree tree = new RTree(2, new LinearGutmanSplitStrategy(0, 50, bf), bf);
tree.insert(new float[]{0, 0}, 1);
tree.insert(new float[]{10, 10}, 10);
tree.insert(new float[]{1, 3}, 2);
tree.insert(new float[]{27, 34}, 20);
tree.insert(new float[]{106, 19}, 30);
tree.insert(new float[]{4, 2}, 3);
tree.insert(new float[]{5, 0}, 4);
tree.insert(new float[]{4, 72}, 40);
tree.insert(new float[]{-4, -3}, 5);
tree.insert(new float[]{119, -78}, 50);
Assert.assertEquals(tree.getRoot().getChildren().size(), 10);
ImmutableRTree searchTree = ImmutableRTree.newImmutableFromMutable(tree);
Iterable<ImmutableGenericBitmap> points = searchTree.search(new RadiusBound(new float[]{0, 0}, 5));
ImmutableGenericBitmap finalSet = bf.union(points);
Assert.assertTrue(finalSet.size() >= 5);
Set<Integer> expected = Sets.newHashSet(1, 2, 3, 4, 5);
IntIterator iter = finalSet.iterator();
while (iter.hasNext()) {