]> git.apps.os.sepia.ceph.com Git - ceph-ci.git/commit
test/pybind/rbd: fix tests that compare strings with b''
authorIlya Dryomov <idryomov@gmail.com>
Tue, 4 Jun 2024 19:19:40 +0000 (21:19 +0200)
committerIlya Dryomov <idryomov@gmail.com>
Wed, 5 Jun 2024 06:42:14 +0000 (08:42 +0200)
commit05f7e4f2025c435dca8ae0b34f65425afbc212b5
tree4af548174d8ccfcb97ce649d7a430cffea9e5776
parentc8f71d64951c8f60953caab3f431162c1f898c17
test/pybind/rbd: fix tests that compare strings with b''

assert_not_equal(b'', self.image.id()) is bogus because Image::id()
returns a string (str), not bytes.  If the types don't match, values
are guaranteed to not match.

The same goes for Image::block_name_prefix().

Signed-off-by: Ilya Dryomov <idryomov@gmail.com>
src/test/pybind/test_rbd.py