Fixes missing commit after rgw_write(), as well as conditional
cleanup.
Reorder tests, and split out librgw_file_gp --delete to avoid an
issue w/sysobj cache (temporary).
Signed-off-by: Matt Benjamin <mbenjamin@redhat.com>
(void*) data.c_str(), RGW_WRITE_FLAG_NONE);
ASSERT_EQ(ret, 0);
ASSERT_EQ(nbytes, data.length());
+ /* commit write transaction */
+ ret = rgw_close(fs, object_fh, 0 /* flags */);
+ ASSERT_EQ(ret, 0);
}
}
}
}
+TEST(LibRGW, DELETE_BUCKET) {
+ if (do_delete) {
+ int ret = rgw_unlink(fs, fs->root_fh, bucket_name.c_str(),
+ RGW_UNLINK_FLAG_NONE);
+ ASSERT_EQ(ret, 0);
+ }
+}
+
TEST(LibRGW, CLEANUP) {
if (do_readv) {
// release resources