]> git.apps.os.sepia.ceph.com Git - ceph-ci.git/commit
qa: krbd_parent_overlap.t: fix read test
authorIlya Dryomov <idryomov@gmail.com>
Wed, 28 Aug 2019 15:07:07 +0000 (17:07 +0200)
committerIlya Dryomov <idryomov@gmail.com>
Wed, 28 Aug 2019 15:07:07 +0000 (17:07 +0200)
commitf47e9534202e6dc2079d88ab803a6cf8acaa7f5e
tree3c92bada9c671e53b5dabd0b4ae3dca132fb028d
parentad4782075bde8d84af5fe885dcf74c8cc903b423
qa: krbd_parent_overlap.t: fix read test

It turns out this test has not been triggering the right code path for
a while now (krbd_parent_overlap.t was added just over a year ago, but
the original test goes back a few years).

To do its job it needs an empty clone with the overlap set to somewhere
in the middle of an object.  The test relied on shrinking for this, but
shrinking no longer fits the bill because a copyup is now performed for
the object with the overlap -- we never go to the parent after that.

Let's size the parent so that it ends in the middle of an object and
then grow an empty clone instead.  Also, while reading from page cache
does seem to trigger a read that straddles the overlap, it's not very
reliable, so supplement it with a direct read.

Signed-off-by: Ilya Dryomov <idryomov@gmail.com>
qa/rbd/krbd_parent_overlap.t