@Test
public void testGetNestedTagTagIndexSearchResponseDtoSearchResponseParameter()
{

    SearchResponse searchResponse = mock(SearchResponse.class);
    Aggregations aggregations = mock(Aggregations.class);
    when(searchResponse.getAggregations()).thenReturn(aggregations);
    Nested nestedAggregation = mock(Nested.class);
    when(aggregations.get(TAG_FACET_AGGS)).thenReturn(nestedAggregation);
    Aggregations aggregationAggregations = mock(Aggregations.class);
    when(nestedAggregation.getAggregations()).thenReturn(aggregationAggregations);
    Terms subAggregation = mock(Terms.class);
    when(aggregationAggregations.get(TAGTYPE_CODE_AGGREGATION)).thenReturn(subAggregation);
    List<TagTypeIndexSearchResponseDto> result = elasticsearchHelper.getNestedTagTagIndexSearchResponseDto(searchResponse);
    assertThat("Result is null.", result, is(notNullValue()));
}