@Test
public void arrayContainingObjectsJson() throws LoadException {

  // GIVEN
  String json = "[ { \"a\": 1, \"c\": [{ \"d\" : 4, \"e\" : 4 }, { \"d\" : 5, \"e\" : 5 }]},"
      + "{\"a\": 2, \"c\": [ { \"d\" : 7, \"e\" : 7 }, { \"d\" : 8, \"e\" : 8 }] } ]";
  // WHEN
  TableShard tableShard =
      Iterables.getOnlyElement(loader.load(0L, new BigByteBuffer(json.getBytes()), TABLE, colInfo));
  // THEN
  Assert.assertEquals(tableShard.getLongColumns().size(), 6, "Expected all long columns to be available");
  Set<Triple<Long, List<Long>, List<Long>>> expectedValues = new HashSet<>();
  expectedValues.add(new Triple<>(1L, Arrays.asList(new Long[] { 4L, 5L }), Arrays.asList(new Long[] { 4L, 5L })));
  expectedValues.add(new Triple<>(2L, Arrays.asList(new Long[] { 7L, 8L }), Arrays.asList(new Long[] { 7L, 8L })));
  Set<Triple<Long, List<Long>, List<Long>>> actualValues = new HashSet<>();
  LongStandardColumnShard colA = tableShard.getLongColumns().get("a");
  LongStandardColumnShard colC0D = tableShard.getLongColumns().get(repeatedColNames.repeatedAtIndex("c", 0) + ".d");
  LongStandardColumnShard colC1D = tableShard.getLongColumns().get(repeatedColNames.repeatedAtIndex("c", 1) + ".d");
  LongStandardColumnShard colC0E = tableShard.getLongColumns().get(repeatedColNames.repeatedAtIndex("c", 0) + ".e");
  LongStandardColumnShard colC1E = tableShard.getLongColumns().get(repeatedColNames.repeatedAtIndex("c", 1) + ".e");
  LongStandardColumnShard colCLength = tableShard.getLongColumns().get(repeatedColNames.repeatedLength("c"));
  for (long i = tableShard.getLowestRowId(); i < tableShard.getLowestRowId()
      + tableShard.getNumberOfRowsInShard(); i++) {
    Long valueA = resolveSingleRowValue(colA, i);
    Long valueC0D = resolveSingleRowValue(colC0D, i);
    Long valueC1D = resolveSingleRowValue(colC1D, i);
    Long valueC0E = resolveSingleRowValue(colC0E, i);
    Long valueC1E = resolveSingleRowValue(colC1E, i);
    actualValues.add(new Triple<>(valueA, Arrays.asList(new Long[] { valueC0D, valueC1D }),
        Arrays.asList(new Long[] { valueC0E, valueC1E })));
    Assert.assertEquals((long) resolveSingleRowValue(colCLength, i), 2L,
        "Correct value of length col expected for row " + i);
  }
  Assert.assertEquals(actualValues, expectedValues, "Expected correct values to be encoded");
}