public static List<FieldSchema> convert(Schema schema) {
    return schema.columns().stream()
        .map(col -> new FieldSchema(col.name(), convertToTypeString(col.type()), col.doc()))
        .collect(Collectors.toList());
  }
@Test
  public void testConversionWithoutLastComment() {
    Schema expected = new Schema(
        optional(1, "customer_id", Types.LongType.get(), "customer comment"),
        optional(2, "first_name", Types.StringType.get(), null)
    );

    Schema schema = HiveSchemaUtil.convert(
        Arrays.asList("customer_id", "first_name"),
        Arrays.asList(TypeInfoUtils.getTypeInfoFromTypeString(serdeConstants.BIGINT_TYPE_NAME),
            TypeInfoUtils.getTypeInfoFromTypeString(serdeConstants.STRING_TYPE_NAME)),
        Collections.singletonList("customer comment"));

    assertThat(schema.asStruct()).isEqualTo(expected.asStruct());
  }