deltacloud-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From mar...@apache.org
Subject [2/4] git commit: Tests: buckets_test.rb - adding check to cleanup for whether the collection is supported
Date Fri, 22 Feb 2013 16:15:26 GMT
Tests: buckets_test.rb - adding check to cleanup for whether the collection is supported

TrackedAt: http://tracker.deltacloud.org/patch/727f1e3ce313b594d8b85a2e5db9728b6a5dc6f3


Project: http://git-wip-us.apache.org/repos/asf/deltacloud/repo
Commit: http://git-wip-us.apache.org/repos/asf/deltacloud/commit/05ab34ab
Tree: http://git-wip-us.apache.org/repos/asf/deltacloud/tree/05ab34ab
Diff: http://git-wip-us.apache.org/repos/asf/deltacloud/diff/05ab34ab

Branch: refs/heads/master
Commit: 05ab34ab3d7d25b45fbbfb27cebd697baf6b6551
Parents: 10683b4
Author: Ronelle Landy <rlandy@redhat.com>
Authored: Fri Feb 15 11:38:33 2013 -0500
Committer: marios <marios@redhat.com>
Committed: Fri Feb 22 18:06:27 2013 +0200

----------------------------------------------------------------------
 tests/deltacloud/buckets_test.rb |   16 +++++++++-------
 1 files changed, 9 insertions(+), 7 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/deltacloud/blob/05ab34ab/tests/deltacloud/buckets_test.rb
----------------------------------------------------------------------
diff --git a/tests/deltacloud/buckets_test.rb b/tests/deltacloud/buckets_test.rb
index 3cff7f5..02f517b 100644
--- a/tests/deltacloud/buckets_test.rb
+++ b/tests/deltacloud/buckets_test.rb
@@ -54,13 +54,15 @@ describe 'Deltacloud API buckets collection' do
 
   # delete the bucket/blob we created for the tests
   MiniTest::Unit.after_tests {
-    res = delete("/buckets/#{@@my_bucket}/#{@@my_blob}")
-    unless res.code == 204
-      raise Exception.new("Failed to delete blob #{@@my_blob}")
-    end
-    res = delete("/buckets/#{@@my_bucket}")
-    unless res.code == 204
-      raise Exception.new("Failed to delete bucket #{@@my_bucket}")
+    collection_supported :buckets
+      res = delete("/buckets/#{@@my_bucket}/#{@@my_blob}")
+      unless res.code == 204
+        raise Exception.new("Failed to delete blob #{@@my_blob}")
+      end
+      res = delete("/buckets/#{@@my_bucket}")
+      unless res.code == 204
+        raise Exception.new("Failed to delete bucket #{@@my_bucket}")
+      end
     end
   }
 


Mime
View raw message