test: rbd master/slave notify test should test active features

Fixes: http://tracker.ceph.com/issues/19692
Signed-off-by: Jason Dillaman <dillaman@redhat.com>
This commit is contained in:
Jason Dillaman 2017-04-19 09:26:31 -04:00
parent 7ab93b7779
commit 0dcba41cba

View File

@ -141,8 +141,10 @@ def slave(ioctx):
assert(list(image.list_snaps()) == [])
print("rebuild object map")
image.update_features(RBD_FEATURE_OBJECT_MAP | RBD_FEATURE_FAST_DIFF,
False)
features = image.features() & (
RBD_FEATURE_OBJECT_MAP | RBD_FEATURE_FAST_DIFF)
if features:
image.update_features(features, False)
image.update_features(RBD_FEATURE_OBJECT_MAP, True)
assert((image.flags() & RBD_FLAG_OBJECT_MAP_INVALID) != 0)
image.rebuild_object_map()