From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:36275) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1a3SVG-0004kF-Or for qemu-devel@nongnu.org; Mon, 30 Nov 2015 12:44:43 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1a3SVF-0001w0-Ij for qemu-devel@nongnu.org; Mon, 30 Nov 2015 12:44:42 -0500 References: <1447108773-6836-1-git-send-email-mreitz@redhat.com> <1447108773-6836-25-git-send-email-mreitz@redhat.com> <20151130162302.GH4494@noname.str.redhat.com> From: Max Reitz Message-ID: <565C8AFE.1000706@redhat.com> Date: Mon, 30 Nov 2015 18:44:30 +0100 MIME-Version: 1.0 In-Reply-To: <20151130162302.GH4494@noname.str.redhat.com> Content-Type: multipart/signed; micalg=pgp-sha256; protocol="application/pgp-signature"; boundary="afJKuvaqUCrHuATedGgm1HUbI1EG42DIf" Subject: Re: [Qemu-devel] [PATCH v7 24/24] iotests: Add test for block jobs and BDS ejection List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Kevin Wolf Cc: Alberto Garcia , qemu-block@nongnu.org, John Snow , qemu-devel@nongnu.org, Markus Armbruster , Stefan Hajnoczi , Paolo Bonzini This is an OpenPGP/MIME signed message (RFC 4880 and 3156) --afJKuvaqUCrHuATedGgm1HUbI1EG42DIf Content-Type: text/plain; charset=windows-1252 Content-Transfer-Encoding: quoted-printable On 30.11.2015 17:23, Kevin Wolf wrote: > Am 09.11.2015 um 23:39 hat Max Reitz geschrieben: >> Suggested-by: Paolo Bonzini >> Signed-off-by: Max Reitz >> --- >> tests/qemu-iotests/141 | 166 ++++++++++++++++++++++++++++++++++++= +++++++++ >> tests/qemu-iotests/141.out | 47 +++++++++++++ >> tests/qemu-iotests/group | 1 + >> 3 files changed, 214 insertions(+) >> create mode 100755 tests/qemu-iotests/141 >> create mode 100644 tests/qemu-iotests/141.out >> >> diff --git a/tests/qemu-iotests/141 b/tests/qemu-iotests/141 >> new file mode 100755 >> index 0000000..6a32d56 >> --- /dev/null >> +++ b/tests/qemu-iotests/141 >> @@ -0,0 +1,166 @@ >> +#!/bin/bash >> +# >> +# Test case for ejecting BDSs with block jobs still running on them >> +# >> +# Copyright (C) 2015 Red Hat, Inc. >> +# >> +# This program is free software; you can redistribute it and/or modif= y >> +# it under the terms of the GNU General Public License as published b= y >> +# the Free Software Foundation; either version 2 of the License, or >> +# (at your option) any later version. >> +# >> +# This program is distributed in the hope that it will be useful, >> +# but WITHOUT ANY WARRANTY; without even the implied warranty of >> +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the >> +# GNU General Public License for more details. >> +# >> +# You should have received a copy of the GNU General Public License >> +# along with this program. If not, see . >> +# >> + >> +# creator >> +owner=3Dmreitz@redhat.com >> + >> +seq=3D"$(basename $0)" >> +echo "QA output created by $seq" >> + >> +here=3D"$PWD" >> +tmp=3D/tmp/$$ >> +status=3D1 # failure is the default! >> + >> +_cleanup() >> +{ >> + _cleanup_test_img >> + rm -f "$TEST_DIR/{b,o}.$IMGFMT" >> +} >> +trap "_cleanup; exit \$status" 0 1 2 3 15 >> + >> +# get standard environment, filters and checks >> +. ./common.rc >> +. ./common.filter >> +. ./common.qemu >> + >> +# Needs backing file support >> +_supported_fmt qcow qcow2 qed >=20 > The test doesn't work for me on qcow1. Hm, and I thought I had tested it. Well, block jobs creating an overlay file not being supported on qcow1 is probably all right. >> +echo >> +echo '=3D=3D=3D Testing block-commit =3D=3D=3D' >> +echo >> + >> +# block-commit will send BLOCK_JOB_READY basically immediately, and c= ancelling >> +# the job will consequently result in BLOCK_JOB_COMPLETED being emitt= ed. >> + >> +test_blockjob \ >> + "{'execute': 'block-commit', >> + 'arguments': {'device': 'drv0'}}" \ >> + 'BLOCK_JOB_READY' \ >> + 'BLOCK_JOB_COMPLETED' >=20 > This is commit of the active layer, i.e. just a mirror in disguise. > Should we test a "real" commit block job as well? Well, the op blocker we are testing is set by block_job_create(), so a single block job would have sufficed. But now that I'm trying to test them all, there's no reason not to test the real commit job, too. > Anyway, with qcow1 removed from the list: > Reviewed-by: Kevin Wolf Thanks! Max --afJKuvaqUCrHuATedGgm1HUbI1EG42DIf Content-Type: application/pgp-signature; name="signature.asc" Content-Description: OpenPGP digital signature Content-Disposition: attachment; filename="signature.asc" -----BEGIN PGP SIGNATURE----- Version: GnuPG v2 iQEcBAEBCAAGBQJWXIr+AAoJEDuxQgLoOKytA3EH/RNn2ERbdt2jx87wBBnBqFrA ndMEhIjzobLGyTffkobIuZp1u1oRpjsioyXFn/4eqpKh1upiT6tRguY3zuH+ae3M xtIa/lu+Hxrn38nUg5t9C+kfykLHVsTHECUsFGY56m63zBqOhkHrjQcQdiVkyhx7 dcKIRrdqMQRIS5F7okDKBjFdi5skf1kocVIQ0vJddtHYR62ITz3aTq6vTi8NYrc1 GrJ4QrCHT4DEql4rX+++EV+8ZZc6okY1/AF+EA8rejXV8e8p55JShD8+KlXHSn5K LPJ/sLfRRsKXUnB0oIn18axqM5UbWF7KFARit6mj2qafvVsCX4fnlBPKkjBUjDU= =VVqw -----END PGP SIGNATURE----- --afJKuvaqUCrHuATedGgm1HUbI1EG42DIf--