@Test
public void testGetBusinessObjectDefinitionDescriptionSuggestions()
{

    // Create the business object definition key used to get the business object definition description suggestions
    BusinessObjectDefinitionKey businessObjectDefinitionKey = new BusinessObjectDefinitionKey(NAMESPACE, BDEF_NAME);
    // Create business object definition description suggestion keys.
    BusinessObjectDefinitionDescriptionSuggestionKey key = new BusinessObjectDefinitionDescriptionSuggestionKey(NAMESPACE, BDEF_NAME, USER_ID);
    BusinessObjectDefinitionDescriptionSuggestionKey key2 = new BusinessObjectDefinitionDescriptionSuggestionKey(NAMESPACE, BDEF_NAME, USER_ID_2);
    // Create a list of business object definition description suggestion keys.
    BusinessObjectDefinitionDescriptionSuggestionKeys businessObjectDefinitionDescriptionSuggestionKeys =
        new BusinessObjectDefinitionDescriptionSuggestionKeys(Lists.newArrayList(key, key2));
    // Mock calls to external method.
    when(businessObjectDefinitionDescriptionSuggestionService.getBusinessObjectDefinitionDescriptionSuggestions(businessObjectDefinitionKey))
        .thenReturn(businessObjectDefinitionDescriptionSuggestionKeys);
    // Get all business object definition description suggestions.
    BusinessObjectDefinitionDescriptionSuggestionKeys resultBusinessObjectDefinitionDescriptionSuggestionKeys =
        businessObjectDefinitionDescriptionSuggestionRestController.getBusinessObjectDefinitionDescriptionSuggestions(NAMESPACE, BDEF_NAME);
    // Verify the external calls.
    verify(businessObjectDefinitionDescriptionSuggestionService).getBusinessObjectDefinitionDescriptionSuggestions(businessObjectDefinitionKey);
    verifyNoMoreInteractions(businessObjectDefinitionDescriptionSuggestionService);
    // Validate the returned object.
    assertEquals(businessObjectDefinitionDescriptionSuggestionKeys, resultBusinessObjectDefinitionDescriptionSuggestionKeys);
}