]> git.apps.os.sepia.ceph.com Git - ceph.git/commitdiff
ceph_test_objectstore: match clone_range src and dst offset
authorSage Weil <sage@redhat.com>
Thu, 2 Feb 2017 15:11:11 +0000 (10:11 -0500)
committerSage Weil <sage@redhat.com>
Thu, 2 Feb 2017 15:11:30 +0000 (10:11 -0500)
This is what the OSD does, and BlueStore doesn't necessarily handle
all combinations of different offsets.

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

index 931382e5dcb40a6a582648fc192afaa3c33aeac5..940f5fceb0fe7f5bf1b2a1783f1c3d12c4a9f391 100644 (file)
@@ -2891,11 +2891,11 @@ TEST_P(StoreTest, SimpleCloneRangeTest) {
   hoid2.hobj.pool = -1;
   {
     ObjectStore::Transaction t;
-    t.clone_range(cid, hoid, hoid2, 10, 5, 0);
+    t.clone_range(cid, hoid, hoid2, 10, 5, 10);
     cerr << "Clone range object" << std::endl;
     r = apply_transaction(store, &osr, std::move(t));
     ASSERT_EQ(r, 0);
-    r = store->read(cid, hoid2, 0, 5, newdata);
+    r = store->read(cid, hoid2, 10, 5, newdata);
     ASSERT_EQ(r, 5);
     ASSERT_TRUE(bl_eq(small, newdata));
   }