@Test
  void randomPushsAndPolls() {
    Random rnd = new Random(0);
    int size = 1 + rnd.nextInt(100);
    PriorityQueue<Entry> pq = new PriorityQueue<>(size);
    create(size);
    IntSet set = new IntHashSet();
    int pushCount = 0;
    for (int i = 0; i < 1000; i++) {
      boolean push = pq.isEmpty() || (rnd.nextBoolean());
      if (push) {
        int id = rnd.nextInt(size);
        if (!set.add(id))
          continue;
        long val = (long) (Long.MAX_VALUE * rnd.nextFloat());
        pq.add(new Entry(id, val));
        heap.push(id, val);
        pushCount++;
      } else {
        Entry entry = pq.poll();
        assert entry != null;
        assertEquals(entry.val, heap.peekValue());
        assertEquals(entry.id, heap.poll());
        assertEquals(pq.size(), heap.size());
        set.removeAll(entry.id);
      }
    }
    assertTrue(pushCount > 0);
  }
Ported from <a href=
"https://github.com/graphhopper/graphhopper/blob/master/core/src/test/java/com/graphhopper/coll/MinHeapWithUpdateTest.java">GraphHopper</a>
and modified to use long instead of float values, use stable random seed for reproducibility, and to use new
implementations.
planetiler-core/src/test/java/com/onthegomap/planetiler/collection/MinHeapTest.java