/** ********************* Enterprise Limits ********************** */
  public void testCreateLimits() throws SecurityException, NoSuchMethodException, IOException {
    EnterpriseDto enterprise = EnterpriseResources.enterprisePut();
    DatacenterDto datacenter = InfrastructureResources.datacenterPut();
    DatacenterLimitsDto limits = EnterpriseResources.datacenterLimitsPost();

    Method method =
        EnterpriseAsyncClient.class.getMethod(
            "createLimits", EnterpriseDto.class, DatacenterDto.class, DatacenterLimitsDto.class);
    GeneratedHttpRequest<EnterpriseAsyncClient> request =
        processor.createRequest(method, 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()),
        DatacenterLimitsDto.BASE_MEDIA_TYPE,
        false);

    assertResponseParserClassEquals(method, request, ParseXMLWithJAXB.class);
    assertSaxResponseParserClassEquals(method, null);
    assertExceptionParserClassEquals(method, null);

    checkFilters(request);
  }
  public void testUpdate() {
    enterprise.setName("Updated Enterprise");
    enterprise.update();

    // Recover the updated enterprise
    EnterpriseDto updated = env.enterpriseApi.getEnterprise(enterprise.getId());

    assertEquals(updated.getName(), "Updated Enterprise");
  }