@Test
public void testCreateSearchIndexActivation()
{

    // Create a search index activation create request.
    SearchIndexActivationCreateRequest searchIndexActivationCreateRequest = new SearchIndexActivationCreateRequest(new SearchIndexKey(SEARCH_INDEX_NAME));
    // Create a search index activation response.
    SearchIndexActivation searchIndexActivation =
        new SearchIndexActivation(new SearchIndexKey(SEARCH_INDEX_NAME), SEARCH_INDEX_TYPE, SEARCH_INDEX_STATUS, SEARCH_INDEX_ACTIVE_FLAG, CREATED_BY,
            CREATED_ON, UPDATED_ON);
    // Mock the call to the search index activation service.
    when(searchIndexActivationService.createSearchIndexActivation(searchIndexActivationCreateRequest)).thenReturn(searchIndexActivation);
    // Create a search index activation.
    SearchIndexActivation response = searchIndexActivationRestController.createSearchIndexActivation(searchIndexActivationCreateRequest);
    // Verify the calls.
    verify(searchIndexActivationService, times(1)).createSearchIndexActivation(searchIndexActivationCreateRequest);
    // Validate the returned object.
    assertEquals(searchIndexActivation, response);
}