nacx approved this pull request.
Just a couple minors. Will merge once addressed.
> +import javax.ws.rs.Path;
+import javax.ws.rs.Produces;
+import javax.ws.rs.core.MediaType;
+
+@RequestFilters({ BasicAuthentication.class, OrganisationIdFilter.class })
+@Consumes(MediaType.APPLICATION_JSON)
+@Path("/caas/2.7/image")
+public interface CustomerImageApi {
+
+ @Named("image:deleteCustomerImage")
+ @POST
+ @Path("/deleteCustomerImage")
+ @Produces(MediaType.APPLICATION_JSON)
+ @MapBinder(BindToJsonPayload.class)
+ @Fallback(Fallbacks.VoidOnNotFoundOr404.class)
+ void deleteCustomerImage(@PayloadParam("id") String id);
Usually better to return a boolean, and use the return false fallback.
> assertNotNull(cloneImageId);
assertTrue(serverNormalPredicate.apply(serverId), "server was not NORMAL
after timeout");
}
+ @Test(dependsOnMethods = "testCloneServerToMakeCustomerImage")
+ public void testListCustomerImages() {
+ FluentIterable<CustomerImage> customerImages =
api.getServerImageApi().listCustomerImages().concat();
+ assertNotNull(customerImages);
+ for (CustomerImage customerImage : customerImages) {
+ assertNotNull(customerImage);
+ }
Instead of asserting not null, let's better just check if the image we're
interested in is in the list.
> @@ -89,8 +89,17 @@ public void setUp() {
datacenters = getZones();
}
+ // private Set<String> getZones() {
+ // return
ctx.utils().injector().getInstance(ZoneIdsSupplier.class).get();
+ // }
+
+ // TODO this leads to a warning - WARNING: failed to find key for value
https://api-na.dimensiondata.com in {au=https://api-au.dimensiondata.com};
choosing first: au
Can you send an email to the dev@ mailing list with the details of what you are
trying to achieve, the current config, and the failure? Just to have the whole
context outside this PR and we can help properly.
--
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/jclouds/jclouds-labs/pull/446#pullrequestreview-166008822