@Test
public void arrayContainingDifferentLengthLongsJson() throws LoadException {

  // GIVEN
  String json = "[ { \"a\": 1, \"c\": [4, 5, 6]}," + "{\"a\": 2, \"c\": [ 1 ] } ]";
  // WHEN
  TableShard tableShard =
      Iterables.getOnlyElement(loader.load(0L, new BigByteBuffer(json.getBytes()), TABLE, colInfo));
  // THEN
  Assert.assertEquals(tableShard.getLongColumns().size(), 5, "Expected all long columns to be available");
  Set<Pair<Long, List<Long>>> expectedValues = new HashSet<>();
  expectedValues.add(new Pair<>(1L, Arrays.asList(new Long[] { 4L, 5L, 6L })));
  expectedValues.add(new Pair<>(2L, Arrays.asList(new Long[] { 1L })));
  Set<Pair<Long, List<Long>>> actualValues = new HashSet<>();
  LongStandardColumnShard colA = tableShard.getLongColumns().get("a");
  LongStandardColumnShard[] colC =
      new LongStandardColumnShard[] { tableShard.getLongColumns().get(repeatedColNames.repeatedAtIndex("c", 0)),
          tableShard.getLongColumns().get(repeatedColNames.repeatedAtIndex("c", 1)),
          tableShard.getLongColumns().get(repeatedColNames.repeatedAtIndex("c", 2)) };
  LongStandardColumnShard colCLength = tableShard.getLongColumns().get(repeatedColNames.repeatedLength("c"));
  for (long i = tableShard.getLowestRowId(); i < tableShard.getLowestRowId()
      + tableShard.getNumberOfRowsInShard(); i++) {
    Long valueA = resolveSingleRowValue(colA, i);
    List<Long> valueC = new ArrayList<>();
    for (int c = 0; c < resolveSingleRowValue(colCLength, i); c++)
      valueC.add(resolveSingleRowValue(colC[c], i));
    actualValues.add(new Pair<>(valueA, valueC));
  }
  Assert.assertEquals(actualValues, expectedValues, "Expected correct values to be encoded");
}