]> git.apps.os.sepia.ceph.com Git - ceph-ci.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:56:00 +0000 (12:56 +0100)
commit29fb251298b58b4517c4b4a3998eb526c9dde6fa
tree19c8210e7a22bf9c5a0b7abfb67c432c8e3ef024
parent8801950d0d222938805a73c817c6a8233f77e9e9
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