]> git.apps.os.sepia.ceph.com Git - ceph.git/commit
test/librbd: make ListSnapsWholeObject actually test stuff
authorIlya Dryomov <idryomov@gmail.com>
Sun, 19 Nov 2023 21:44:28 +0000 (22:44 +0100)
committerIlya Dryomov <idryomov@gmail.com>
Mon, 11 Dec 2023 11:44:40 +0000 (12:44 +0100)
commit06fedbffe3d0e978ab49a12b11e3be4b41c4962b
tree72372d2299ca8d6d872572bc81c473ee01f63fbf
parentdf8ecf3dda1b6b6eaa79f8f82f5470c0c4e2cc2b
test/librbd: make ListSnapsWholeObject actually test stuff

Despite being added in commit 66dd53d9c4d9 ("librbd: optionally return
full object extent for any snapshot deltas") ostensibly to test the new
LIST_SNAPS_FLAG_WHOLE_OBJECT code, it surely doesn't do that because
the flag isn't even passed to MockObjectListSnapsRequest::create().

I can only guess, but it looks like snap ID 3 was intended to be
a starting point.  Otherwise, with 0 and CEPH_NOSNAP passed as snap
IDs, the overlap that is set up for the clone wouldn't affect the
computation in any way.

Use snap ID 3 as a starting point and run both with and without
LIST_SNAPS_FLAG_WHOLE_OBJECT on the same snapset to pinpoint the
difference.

Signed-off-by: Ilya Dryomov <idryomov@gmail.com>
(cherry picked from commit bd52297a71100dd35874fa3aeda81fca1d828b38)
src/test/librbd/io/test_mock_ObjectRequest.cc