@Test
public void testCreateResources_wrongConfigurationsStructure_withWrongConfigMapSize() throws ResourceAlreadyExistsException, SystemException,
    UnsupportedPropertyException, NoSuchParentResourceException
{

  Request request = createMock(Request.class);
  Set<Map<String, Object>> setProperties = getBlueprintTestProperties();
  Map<String, String> requestInfoProperties = new HashMap<String, String>();
  String configurationData = "{\"configurations\":[{\"config-type1\":{\"properties\" :{\"property\":\"property-value\"}},"
      + "\"config-type2\" : {\"properties_attributes\" : {\"property\" : \"property-value\"}, \"properties\" : {\"property\" : \"property-value\"}}}"
      + "]}";
  requestInfoProperties.put(Request.REQUEST_INFO_BODY_PROPERTY, configurationData);
  // set expectations
  expect(request.getProperties()).andReturn(setProperties);
  expect(request.getRequestInfoProperties()).andReturn(requestInfoProperties);
  replay(dao, metaInfo, request);
  // end expectations
  try {
    provider.createResources(request);
    fail("Exception expected");
  } catch (IllegalArgumentException e) {
    //expected exception
    assertEquals(BlueprintResourceProvider.CONFIGURATION_MAP_SIZE_CHECK_ERROR_MESSAGE, e.getMessage());
  }
  verify(dao, metaInfo, request);
}