You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@jclouds.apache.org by ga...@apache.org on 2015/01/10 07:18:52 UTC

jclouds git commit: Add test for UpdateContainerOptions.anybodyRead

Repository: jclouds
Updated Branches:
  refs/heads/master 694558db0 -> 2c32cfee3


Add test for UpdateContainerOptions.anybodyRead


Project: http://git-wip-us.apache.org/repos/asf/jclouds/repo
Commit: http://git-wip-us.apache.org/repos/asf/jclouds/commit/2c32cfee
Tree: http://git-wip-us.apache.org/repos/asf/jclouds/tree/2c32cfee
Diff: http://git-wip-us.apache.org/repos/asf/jclouds/diff/2c32cfee

Branch: refs/heads/master
Commit: 2c32cfee3b60e35f2df978245e20134d78e54903
Parents: 694558d
Author: Andrew Gaul <ga...@apache.org>
Authored: Sun Jan 4 20:39:42 2015 -0800
Committer: Andrew Gaul <ga...@apache.org>
Committed: Fri Jan 9 22:18:19 2015 -0800

----------------------------------------------------------------------
 .../swift/v1/features/ContainerApiLiveTest.java      | 15 +++++++++++++++
 1 file changed, 15 insertions(+)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/jclouds/blob/2c32cfee/apis/openstack-swift/src/test/java/org/jclouds/openstack/swift/v1/features/ContainerApiLiveTest.java
----------------------------------------------------------------------
diff --git a/apis/openstack-swift/src/test/java/org/jclouds/openstack/swift/v1/features/ContainerApiLiveTest.java b/apis/openstack-swift/src/test/java/org/jclouds/openstack/swift/v1/features/ContainerApiLiveTest.java
index bf2ba98..b334712 100644
--- a/apis/openstack-swift/src/test/java/org/jclouds/openstack/swift/v1/features/ContainerApiLiveTest.java
+++ b/apis/openstack-swift/src/test/java/org/jclouds/openstack/swift/v1/features/ContainerApiLiveTest.java
@@ -16,6 +16,7 @@
  */
 package org.jclouds.openstack.swift.v1.features;
 
+import static org.assertj.core.api.Assertions.assertThat;
 import static org.testng.Assert.assertEquals;
 import static org.testng.Assert.assertFalse;
 import static org.testng.Assert.assertNotNull;
@@ -131,6 +132,20 @@ public class ContainerApiLiveTest extends BaseSwiftApiLiveTest<SwiftApi> {
       }
    }
 
+   public void testUpdateContainer() throws Exception {
+      for (String regionId : regions) {
+         ContainerApi containerApi = api.getContainerApi(regionId);
+         assertThat(containerApi.create(name)).isTrue();
+
+         assertThat(containerApi.get(name).getAnybodyRead().get()).isFalse();
+
+         assertThat(containerApi.update(name, new UpdateContainerOptions().anybodyRead())).isTrue();
+         assertThat(containerApi.get(name).getAnybodyRead().get()).isTrue();
+
+         assertThat(containerApi.deleteIfEmpty(name)).isTrue();
+      }
+   }
+
    public void testGet() throws Exception {
       for (String regionId : regions) {
          Container container = api.getContainerApi(regionId).get(name);