public static Map<String, ResourceModel> buildResourceModels(final Set<Class<?>> restliAnnotatedClasses)
  {
    Map<String, ResourceModel> rootResourceModels = new HashMap<>();
    Map<Class<?>, ResourceModel> resourceModels = new HashMap<>();

    for (Class<?> annotatedClass : restliAnnotatedClasses)
    {
      processResourceInOrder(annotatedClass, resourceModels, rootResourceModels);
    }

    return rootResourceModels;
  }
@Test(dataProvider = "badResources")
  public void testBadResource(Class<?> resourceClass, String errorMsg)
  {
    Set<Class<?>> set = new HashSet<>();
    set.add(ParentResource.class);
    set.add(resourceClass);
    try
    {
      RestLiApiBuilder.buildResourceModels(set);
      Assert.fail("Building api with BadResource should throw " + ResourceConfigException.class);
    }
    catch (ResourceConfigException e)
    {
      Assert.assertTrue(e.getMessage().contains(errorMsg));
    }
  }