]> git-server-git.apps.pok.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:51:51 +0000 (12:51 +0100)
commitc72a0faa636251d3816d77a7d197412d04dd443e
tree0e9769afca9a40924118565caaeb90e829cb0e41
parentaa537d34a85309057684192986d6f208dcc596c5
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