@Override @Consumes(MediaType.APPLICATION_JSON) public VirtualGuest expected() { return VirtualGuest.builder() .id(416700) .accountId(93750) .billingItemId(7184019) .createDate( new SimpleDateFormatDateService().iso8601SecondsDateParse("2011-10-01T11:47:35-08:00")) .metricPollDate( new SimpleDateFormatDateService().iso8601SecondsDateParse("2011-10-02T02:32:00-08:00")) .dedicatedAccountHostOnly(true) .domain("me.org") .fullyQualifiedDomainName("node1703810489.me.org") .hostname("node1703810489") .maxCpu(1) .maxCpuUnits("CORE") .maxMemory(1024) .modifyDate( new SimpleDateFormatDateService().iso8601SecondsDateParse("2011-10-02T03:18:12-08:00")) .primaryBackendIpAddress("10.37.102.195") .primaryIpAddress("173.192.29.187") .startCpus(1) .statusId(1001) .uuid("02ddbbba-9225-3d54-6de5-fc603b309dd8") .operatingSystem( OperatingSystem.builder() .id(913824) .passwords( Password.builder().id(729122).username("root").password("KnJqhC2l").build()) .build()) .datacenter(Datacenter.builder().id(3).name("dal01").longName("Dallas").build()) // TODO: maybe powerState can be flattened like billingItemId .powerState(new PowerState(VirtualGuest.State.PAUSED)) .build(); }
@Override @Consumes(MediaType.APPLICATION_JSON) public ContainerVirtualGuestConfiguration expected() { return ContainerVirtualGuestConfiguration.builder() .blockDevices( ContainerVirtualGuestConfigurationOption.builder() .productItemPrice( ProductItemPrice.builder() .hourlyRecurringFee(0) .recurringFee("0") .item(ProductItem.builder().description("25 GB (SAN)").build()) .build()) .template( VirtualGuest.builder() .blockDevices( VirtualGuestBlockDevice.builder() .device("0") .diskImage(VirtualDiskImage.builder().capacity(25).build()) .build()) .localDiskFlag(false) .build()) .build()) .datacenters( ContainerVirtualGuestConfigurationOption.builder() .template( VirtualGuest.builder() .datacenter(Datacenter.builder().name("ams01").build()) .build()) .build()) .memory( ContainerVirtualGuestConfigurationOption.builder() .productItemPrice( ProductItemPrice.builder() .hourlyRecurringFee(.02f) .recurringFee("14") .item(ProductItem.builder().description("1 GB").build()) .build()) .template(VirtualGuest.builder().maxMemory(1024).build()) .build()) .networkComponents( ContainerVirtualGuestConfigurationOption.builder() .productItemPrice( ProductItemPrice.builder() .hourlyRecurringFee(0) .recurringFee("0") .item( ProductItem.builder() .description("10 Mbps Public & Private Networks") .build()) .build()) .template( VirtualGuest.builder() .networkComponents( VirtualGuestNetworkComponent.builder().maxSpeed(10).build()) .build()) .build()) .operatingSystems( ContainerVirtualGuestConfigurationOption.builder() .productItemPrice( ProductItemPrice.builder() .hourlyRecurringFee(0) .recurringFee("0") .item( ProductItem.builder() .description("CentOS 6.x - Minimal Install (64 bit)") .build()) .build()) .template( VirtualGuest.builder().operatingSystemReferenceCode("CENTOS_6_64").build()) .build()) .processors( ContainerVirtualGuestConfigurationOption.builder() .productItemPrice( ProductItemPrice.builder() .hourlyRecurringFee(.022f) .recurringFee("15") .item(ProductItem.builder().description("1 x 2.0 GHz Core").build()) .build()) .template(VirtualGuest.builder().startCpus(1).build()) .build()) .build(); }