Package org.jclouds.dynect.v3

Examples of org.jclouds.dynect.v3.DynECTApi


      assertEquals(success.getRecordApiForZone("jclouds.org").scheduleDelete(id), Job.success(285372457l));
   }

   public void testDeleteWhenResponseIs404() {
      DynECTApi fail = requestsSendResponses(createSession, createSessionResponse, delete, notFound);
      assertNull(fail.getRecordApiForZone("jclouds.org").scheduleDelete(id));
   }
View Full Code Here


   HttpResponse listResponse = HttpResponse.builder().statusCode(OK.getStatusCode())
         .payload(payloadFromResourceWithContentType("/list_geo_regiongroups.json", APPLICATION_JSON)).build();

   public void testListWhenResponseIs2xx() {
      DynECTApi success = requestsSendResponses(createSession, createSessionResponse, list, listResponse);
      assertEquals(success.getGeoRegionGroupApiForService("srv").list().toString(),
            new ListGeoRegionGroupsResponseTest().expected().toString());
   }
View Full Code Here

   HttpResponse getResponse = HttpResponse.builder().statusCode(OK.getStatusCode())
         .payload(payloadFromResourceWithContentType("/get_geo_regiongroup.json", APPLICATION_JSON)).build();

   public void testGetWhenResponseIs2xx() {
      DynECTApi success = requestsSendResponses(createSession, createSessionResponse, get, getResponse);
      assertEquals(success.getGeoRegionGroupApiForService("srv").get("Everywhere Else").toString(),
            new GetGeoRegionGroupResponseTest().expected().toString());
   }
View Full Code Here

   HttpResponse listResponse = HttpResponse.builder().statusCode(OK.getStatusCode())
         .payload(payloadFromResourceWithContentType("/list_geo_services.json", APPLICATION_JSON)).build();

   public void testListWhenResponseIs2xx() {
      DynECTApi success = requestsSendResponses(createSession, createSessionResponse, list, listResponse);
      assertEquals(success.getGeoServiceApi().list().toString(), new ListGeoServicesResponseTest().expected()
            .toString());
   }
View Full Code Here

   HttpResponse getResponse = HttpResponse.builder().statusCode(OK.getStatusCode())
         .payload(payloadFromResourceWithContentType("/get_geo_service.json", APPLICATION_JSON)).build();

   public void testGetWhenResponseIs2xx() {
      DynECTApi success = requestsSendResponses(createSession, createSessionResponse, get, getResponse);
      assertEquals(success.getGeoServiceApi().get("srv").toString(), new GetGeoServiceResponseTest().expected()
            .toString());
   }
View Full Code Here

                            .fqdn("jclouds.org")
                            .type("SOA")
                            .id(50976579l).build();

   public void testGetWhenResponseIs2xx() {
      DynECTApi success = requestsSendResponses(createSession, createSessionResponse, getSOA, soaResponse);
      assertEquals(success.getRecordApiForZone("jclouds.org").get(soaId).toString(),
                   new GetRecordResponseTest().expected().toString());
   }
View Full Code Here

      assertEquals(success.getRecordApiForZone("jclouds.org").get(soaId).toString(),
                   new GetRecordResponseTest().expected().toString());
   }

   public void testGetWhenResponseIs404() {
      DynECTApi fail = requestsSendResponses(createSession, createSessionResponse, getSOA, notFound);
      assertNull(fail.getRecordApiForZone("jclouds.org").get(soaId));
   }
View Full Code Here

        .fqdn("jclouds.org")
        .type("AAAA")
        .id(50976579l).build();

   public void testGetAAAAWhenResponseIs2xx() {
      DynECTApi success = requestsSendResponses(createSession, createSessionResponse, getAAAA, aaaaResponse);
      assertEquals(success.getRecordApiForZone("jclouds.org").getAAAA(aaaaId.getFQDN(), aaaaId.getId()).toString(),
                   new GetAAAARecordResponseTest().expected().toString());
   }
View Full Code Here

      assertEquals(success.getRecordApiForZone("jclouds.org").getAAAA(aaaaId.getFQDN(), aaaaId.getId()).toString(),
                   new GetAAAARecordResponseTest().expected().toString());
   }

   public void testGetAAAAWhenResponseIs404() {
      DynECTApi fail = requestsSendResponses(createSession, createSessionResponse, getAAAA, notFound);
      assertNull(fail.getRecordApiForZone("jclouds.org").getAAAA(aaaaId.getFQDN(), aaaaId.getId()));
   }
View Full Code Here

        .fqdn("jclouds.org")
        .type("A")
        .id(50976579l).build();

   public void testGetAWhenResponseIs2xx() {
      DynECTApi success = requestsSendResponses(createSession, createSessionResponse, getA, aResponse);
      assertEquals(success.getRecordApiForZone("jclouds.org").getA(aId.getFQDN(), aId.getId()).toString(),
                   new GetARecordResponseTest().expected().toString());
   }
View Full Code Here

TOP

Related Classes of org.jclouds.dynect.v3.DynECTApi

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.