]> git.apps.os.sepia.ceph.com Git - ceph.git/commitdiff
unittest_bluestore_types: fix gc tests
authorSage Weil <sage@redhat.com>
Wed, 19 Oct 2016 18:12:42 +0000 (14:12 -0400)
committerSage Weil <sage@redhat.com>
Wed, 19 Oct 2016 18:12:42 +0000 (14:12 -0400)
In ef8989ce7417034aa715de4fe83d1f0363c044f4 we disabled
gc for non-compressed blobs.  So mark these test ones as
compressed.

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

index 878c09e007fe11005c9b05ab23405924e77c6f13..de1abebb8791eb5dce60032a26c79d40dc541a52 100644 (file)
@@ -1012,6 +1012,9 @@ TEST(ExtentMap, GarbageCollectorTest)
   b1->shared_blob = new BlueStore::SharedBlob(-1, string(), &cache);
   b2->shared_blob = new BlueStore::SharedBlob(-1, string(), &cache);
   b3->shared_blob = new BlueStore::SharedBlob(1, string(), &cache);
+  b1->dirty_blob().set_flag(bluestore_blob_t::FLAG_COMPRESSED);
+  b2->dirty_blob().set_flag(bluestore_blob_t::FLAG_COMPRESSED);
+  b3->dirty_blob().set_flag(bluestore_blob_t::FLAG_COMPRESSED);
 
   em.extent_map.insert(*new BlueStore::Extent(0, 0, 100, 3, b1));
   em.extent_map.insert(*new BlueStore::Extent(100, 0, 50, 3, b2));