]> git-server-git.apps.pok.os.sepia.ceph.com Git - ceph.git/commitdiff
test/rgw: add multisite test_suspended_delete_marker_full_sync()
authorCasey Bodley <cbodley@redhat.com>
Tue, 22 Jan 2019 15:56:56 +0000 (10:56 -0500)
committerPrashant D <pdhange@redhat.com>
Tue, 29 Jan 2019 23:28:44 +0000 (18:28 -0500)
Signed-off-by: Casey Bodley <cbodley@redhat.com>
(cherry picked from commit 8686b6429c520aff388fb64d46172d691d71950d)

src/test/rgw/rgw_multi/tests.py

index ee8b02fd82299d26720be62c58c4ff76ae6ce61d..c3376b5561d9861aa9542a9ec75ab97a6de3a920 100644 (file)
@@ -726,6 +726,30 @@ def test_delete_marker_full_sync():
     for _, bucket in zone_bucket:
         zonegroup_bucket_checkpoint(zonegroup_conns, bucket.name)
 
+def test_suspended_delete_marker_full_sync():
+    zonegroup = realm.master_zonegroup()
+    zonegroup_conns = ZonegroupConns(zonegroup)
+    buckets, zone_bucket = create_bucket_per_zone(zonegroup_conns)
+
+    # enable/suspend versioning
+    for _, bucket in zone_bucket:
+        bucket.configure_versioning(True)
+        bucket.configure_versioning(False)
+    zonegroup_meta_checkpoint(zonegroup)
+
+    for zone, bucket in zone_bucket:
+        # upload an initial object
+        key1 = new_key(zone, bucket, 'obj')
+        key1.set_contents_from_string('')
+
+        # create a delete marker
+        key2 = new_key(zone, bucket, 'obj')
+        key2.delete()
+
+    # wait for full sync
+    for _, bucket in zone_bucket:
+        zonegroup_bucket_checkpoint(zonegroup_conns, bucket.name)
+
 def test_bucket_versioning():
     buckets, zone_bucket = create_bucket_per_zone_in_realm()
     for _, bucket in zone_bucket: