@Test
public void getAvroSchemaForFeedSetupTest() {

    final Schema schema = SchemaBuilder
        .record("test_record")
        .namespace("my_schema")
        .fields()
            .name("po_id").type().nullable().intType().intDefault(0)
            .name("customer_name").type().nullable().stringType().stringDefault("null")
            .name("total_amount").type().nullable().stringType().stringDefault("null")
            .name("is_urgent").type().nullable().booleanType().booleanDefault(false)
            .name("last_update_time").type().nullable().stringType().stringDefault("null")
            .name("photo").type().nullable().bytesType().bytesDefault("null")
            .name("identifier").type().nullable().longType().longDefault(0)
            .name("state").type().stringType().stringDefault("null")
        .endRecord();
    String obtained = JdbcCommon.getAvroSchemaForFeedSetup(schema);
    String expected = "po_id|int||0|0|0\n"
                    + "customer_name|string||0|0|0\n"
                    + "total_amount|string||0|0|0\n"
                    + "is_urgent|boolean||0|0|0\n"
                    + "last_update_time|string||0|0|0\n"
                    + "photo|binary||0|0|0\n"
                    + "identifier|bigint||0|0|0\n"
                    + "state|string||0|0|0";
    assertEquals("Avro schema not mapped correctly for feed table setup", expected, obtained);
}