]> git.apps.os.sepia.ceph.com Git - ceph.git/commitdiff
ceph_test_objectstore: clean up on finish of MoveRename 2127/head
authorSage Weil <sage@redhat.com>
Tue, 22 Jul 2014 13:53:41 +0000 (06:53 -0700)
committerSage Weil <sage@redhat.com>
Wed, 23 Jul 2014 21:48:14 +0000 (14:48 -0700)
Otherwise, we leave collections around, and the next test fails.

Signed-off-by: Sage Weil <sage@redhat.com>
src/test/objectstore/store_test.cc

index f061a425c1c547183b2dfcf936934fbdf6aa3d01..58019e318bb278067124ed850bda6ea7f9b53134 100644 (file)
@@ -1378,6 +1378,14 @@ TEST_P(StoreTest, MoveRename) {
     ASSERT_TRUE(newomap.count("omap_key"));
     ASSERT_TRUE(newomap["omap_key"].contents_equal(omap["omap_key"]));
   }
+  {
+    ObjectStore::Transaction t;
+    t.remove(cid, oid);
+    t.remove_collection(cid);
+    t.remove_collection(temp_cid);
+    r = store->apply_transaction(t);
+    ASSERT_EQ(r, 0);
+  }
 }
 
 TEST_P(StoreTest, BigRGWObjectName) {