@Test
public void repeatedMessage() {

  Message message =
      TestProtos.RepeatedMessage.newBuilder()
          .addSimpleMessage(SimpleMessage.newBuilder().setName("bruce"))
          .addSimpleMessage(SimpleMessage.newBuilder().setName("lee"))
          .build();
  Function<Message, ?> getter =
      protobufPath(message.getDescriptorForType(), "$.simple_message[1].name");
  assertThat(getter.apply(message), is("lee"));
}