On 2018-05-25 18:33, Kevin Wolf wrote: > This rewrites the test case 210 to work with the new x-blockdev-create > job rather than the old synchronous version of the command. > > All of the test cases stay the same as before, but in order to be able > to implement proper job handling, the test case is rewritten in Python. > > Signed-off-by: Kevin Wolf <kw...@redhat.com> > --- > tests/qemu-iotests/210 | 393 > ++++++++++++++++++------------------------ > tests/qemu-iotests/210.out | 189 ++++++++++++++------ > tests/qemu-iotests/group | 2 +- > tests/qemu-iotests/iotests.py | 12 +- > 4 files changed, 310 insertions(+), 286 deletions(-)
Reviewed-by: Max Reitz <mre...@redhat.com> > diff --git a/tests/qemu-iotests/210 b/tests/qemu-iotests/210 > index e607c0d296..ff4fddea56 100755 > --- a/tests/qemu-iotests/210 > +++ b/tests/qemu-iotests/210 [...] > + # > + # Invalid sizes > + # > + > + # TODO Negative image sizes aren't handled correctly, but this is a > problem > + # with QAPI's implementation of the 'size' type and affects other > commands as > + # well. Once this is fixed, we may want to add a test case here. > + > + # 1. 2^64 - 512 > + # 2. 2^63 = 8 EB (qemu-img enforces image sizes less than this) > + # 3. 2^63 - 512 (generally valid, but with the crypto header the file > will > + # exceed 63 bits) > + iotests.log("=== Invalid sizes ===") > + iotests.log("") > + > + vm.launch() > + for size in [ 18446744073709551104, 9223372036854775808, > 9223372036854775296 ]: Maybe this would be nice in patch 8 as well. Max > + blockdev_create(vm, { 'driver': imgfmt, > + 'file': 'node0', > + 'key-secret': 'keysec0', > + 'size': size }) > + vm.shutdown(
signature.asc
Description: OpenPGP digital signature