@Before
  public void setup() throws IOException {
    tsQueryResults =
        DruidStorageHandlerUtils.SMILE_MAPPER.writeValueAsBytes(DruidStorageHandlerUtils.JSON_MAPPER.readValue(
            TIMESERIES_QUERY_RESULTS,
            new TypeReference<List<Result<TimeseriesResultValue>>>() {
            }));

    topNQueryResults =
        DruidStorageHandlerUtils.SMILE_MAPPER.writeValueAsBytes(DruidStorageHandlerUtils.JSON_MAPPER.readValue(
            TOPN_QUERY_RESULTS,
            new TypeReference<List<Result<TopNResultValue>>>() {
            }));
    groupByQueryResults =
        DruidStorageHandlerUtils.SMILE_MAPPER.writeValueAsBytes(DruidStorageHandlerUtils.JSON_MAPPER.readValue(
            GROUP_BY_QUERY_RESULTS,
            new TypeReference<List<Row>>() {
            }));
    groupByTimeExtractQueryResults =
        DruidStorageHandlerUtils.SMILE_MAPPER.writeValueAsBytes(DruidStorageHandlerUtils.JSON_MAPPER.readValue(
            GB_TIME_EXTRACTIONS_RESULTS,
            new TypeReference<List<Row>>() {
            }));
    groupByMonthExtractQueryResults =
        DruidStorageHandlerUtils.SMILE_MAPPER.writeValueAsBytes(DruidStorageHandlerUtils.JSON_MAPPER.readValue(
            GB_MONTH_EXTRACTIONS_RESULTS,
            new TypeReference<List<Row>>() {
            }));
    scanQueryResults =
        DruidStorageHandlerUtils.SMILE_MAPPER.writeValueAsBytes(DruidStorageHandlerUtils.JSON_MAPPER.readValue(
            SCAN_QUERY_RESULTS,
            new TypeReference<List<ScanResultValue>>() {
            }));
  }
Basic tests for Druid SerDe. The examples are taken from Druid 0.9.1.1
documentation.
druid-handler/src/test/org/apache/hadoop/hive/druid/serde/TestDruidSerDe.java