}
/*********************** Enterprise Limits ********************** */
public void testCreateLimits() throws SecurityException, NoSuchMethodException, IOException {
EnterpriseDto enterprise = EnterpriseResources.enterprisePut();
DatacenterDto datacenter = InfrastructureResources.datacenterPut();
DatacenterLimitsDto limits = EnterpriseResources.datacenterLimitsPost();
Invokable<?, ?> method = method(EnterpriseApi.class, "createLimits", EnterpriseDto.class, DatacenterDto.class,
DatacenterLimitsDto.class);
GeneratedHttpRequest request = processor.apply(Invocation.create(method,
ImmutableList.<Object> of(enterprise, datacenter, limits)));
String limitsUri = enterprise.searchLink("limits").getHref();
String requestURI = String.format("POST %s?datacenter=%d HTTP/1.1", limitsUri, datacenter.getId());
assertRequestLineEquals(request, requestURI);
assertNonPayloadHeadersEqual(request, "Accept: " + DatacenterLimitsDto.BASE_MEDIA_TYPE + "\n");
assertPayloadEquals(request, withHeader(EnterpriseResources.datacenterLimitsPostPayload()),