  @Test
  public void testInternalIdToLongIterator() {

    LongToInternalIntBiMap nodesToIndexBiMap =
        new ArrayBasedLongToInternalIntBiMap(10, 0.5, -1, -1L, nullStatsReceiver);
    int n = 7;
    int[] expectedIndices = new int[n];
    long[] expectedEntries = new long[n];
    for (int i = 0; i < n; i++) {
      expectedIndices[i] = nodesToIndexBiMap.put(i);
      expectedEntries[i] = (long) i;
    }
    IntIterator intIterator = new IntArrayList(expectedIndices).iterator();

    InternalIdToLongIterator internalIdToLongIterator =
        new InternalIdToLongIterator(nodesToIndexBiMap, new IdentityEdgeTypeMask());

    internalIdToLongIterator.resetWithIntIterator(new WithEdgeMetadataIntIteratorImpl(intIterator));
    assertEquals(new LongArrayList(expectedEntries), new LongArrayList(internalIdToLongIterator));
  }