}
}
}
{
// Check (lat, lon) index
Operator plan = indexScan_Default(latLonIndexRowType);
int rowsRemaining = zToId.size() / 2;
if ((zToId.size() % 2) == 1) {
rowsRemaining += 1;
}
long[][] expected = new long[rowsRemaining][];
int r = 0;
for (Map.Entry<Long, Integer> entry : zToId.entrySet()) {
long z = entry.getKey();
int id = entry.getValue();
// Only even ids should remain
if ((id % 2) == 0) {
expected[r++] = new long[]{z, id};
}
}
compareRows(rows(latLonIndexRowType.physicalRowType(), sort(expected)), cursor(plan, queryContext, queryBindings));
}
{
// Check (before, lat, lon) index
Operator plan = indexScan_Default(beforeLatLonIndexRowType);
int rowsRemaining = zToId.size() / 2;
if ((zToId.size() % 2) == 1) {
rowsRemaining += 1;
}
long[][] expected = new long[rowsRemaining][];
int r = 0;
for (Map.Entry<Long, Integer> entry : zToId.entrySet()) {
long z = entry.getKey();
int id = entry.getValue();
// Only even ids should remain
if ((id % 2) == 0) {
expected[r++] = new long[]{before(id), z, id};
}
}
compareRows(rows(beforeLatLonIndexRowType.physicalRowType(), sort(expected)), cursor(plan, queryContext, queryBindings));
}
{
// Check (lat, lon, after) index
Operator plan = indexScan_Default(latLonAfterIndexRowType);
int rowsRemaining = zToId.size() / 2;
if ((zToId.size() % 2) == 1) {
rowsRemaining += 1;
}
long[][] expected = new long[rowsRemaining][];
int r = 0;
for (Map.Entry<Long, Integer> entry : zToId.entrySet()) {
long z = entry.getKey();
int id = entry.getValue();
// Only even ids should remain
if ((id % 2) == 0) {
expected[r++] = new long[]{z, after(id), id};
}
}
compareRows(rows(latLonAfterIndexRowType.physicalRowType(), sort(expected)), cursor(plan, queryContext, queryBindings));
}
{
// Check (before, lat, lon, after) index
Operator plan = indexScan_Default(beforeLatLonAfterIndexRowType);
int rowsRemaining = zToId.size() / 2;
if ((zToId.size() % 2) == 1) {
rowsRemaining += 1;
}
long[][] expected = new long[rowsRemaining][];