From fcfb4e1b2acb055c3068e1c1ebd6be212ceb5095 Mon Sep 17 00:00:00 2001 From: myoungwon oh Date: Mon, 3 Aug 2020 14:35:21 +0900 Subject: [PATCH] src/test: prevent truncate from using write_full Use write instead of write_full to avoid truncate even if set-chunk is set Signed-off-by: Myoungwon Oh --- src/test/librados/tier_cxx.cc | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/src/test/librados/tier_cxx.cc b/src/test/librados/tier_cxx.cc index df584a922b0..987820291a5 100644 --- a/src/test/librados/tier_cxx.cc +++ b/src/test/librados/tier_cxx.cc @@ -4073,8 +4073,7 @@ TEST_F(LibRadosTwoPoolsPP, ManifestSnapRefcount2) { bufferlist bl; bl.append("Thabe cd"); ObjectWriteOperation op; - op.write_full(bl); - ASSERT_EQ(0, ioctx.operate("foo", &op)); + ASSERT_EQ(0, ioctx.write("foo", bl, bl.length(), 0)); } // flush { @@ -4299,8 +4298,7 @@ TEST_F(LibRadosTwoPoolsPP, ManifestFlushSnap) { bufferlist bl; bl.append("There"); ObjectWriteOperation op; - op.write_full(bl); - ASSERT_EQ(0, ioctx.operate("foo", &op)); + ASSERT_EQ(0, ioctx.write("foo", bl, bl.length(), 0)); } // create a snapshot, clone -- 2.47.3