qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: Max Reitz <mreitz@redhat.com>
To: Alberto Garcia <berto@igalia.com>, qemu-block@nongnu.org
Cc: Kevin Wolf <kwolf@redhat.com>, qemu-devel@nongnu.org
Subject: Re: [PATCH] iotests: Drop deprecated 'props' from object-add
Date: Fri, 19 Feb 2021 13:04:00 +0100	[thread overview]
Message-ID: <ff22d21d-ccd8-77e5-1b4c-786e3df79400@redhat.com> (raw)
In-Reply-To: <20210216171653.6543-1-berto@igalia.com>

On 16.02.21 18:16, Alberto Garcia wrote:
> Signed-off-by: Alberto Garcia <berto@igalia.com>
> ---
>   tests/qemu-iotests/087     |  8 ++------
>   tests/qemu-iotests/184     | 18 ++++++------------
>   tests/qemu-iotests/218     |  2 +-
>   tests/qemu-iotests/235     |  2 +-
>   tests/qemu-iotests/245     |  4 ++--
>   tests/qemu-iotests/258     |  7 +++----
>   tests/qemu-iotests/258.out |  4 ++--
>   tests/qemu-iotests/295     |  2 +-
>   tests/qemu-iotests/296     |  2 +-
>   9 files changed, 19 insertions(+), 30 deletions(-)

Reviewed-by: Max Reitz <mreitz@redhat.com>

Two Python syntax nit picks below.

[...]

> diff --git a/tests/qemu-iotests/218 b/tests/qemu-iotests/218
> index ae7c4fb187..cbb38923cf 100755
> --- a/tests/qemu-iotests/218
> +++ b/tests/qemu-iotests/218
> @@ -152,7 +152,7 @@ with iotests.VM() as vm, \
>       vm.launch()
>   
>       ret = vm.qmp('object-add', qom_type='throttle-group', id='tg',
> -                 props={'x-bps-read': 4096})
> +                 x_bps_read = 4096)

To stay consistent, I think there shouldn’t be spaces around '=' here.

(flake8 thinks so, too)

>       assert ret['return'] == {}
>   
>       ret = vm.qmp('blockdev-add',

[..]

> diff --git a/tests/qemu-iotests/258 b/tests/qemu-iotests/258
> index 9a2d33ae5e..65ce02501a 100755
> --- a/tests/qemu-iotests/258
> +++ b/tests/qemu-iotests/258
> @@ -103,10 +103,9 @@ def test_concurrent_finish(write_to_stream_node):
>           vm.qmp_log('object-add',
>                      qom_type='throttle-group',
>                      id='tg',
> -                   props={
> -                       'x-iops-write': 1,
> -                       'x-iops-write-max': 1
> -                   })
> +                   x_iops_write=1,
> +                   x_iops_write_max=1
> +                   )

This indentation looks weird to me now.  Unfortunately, flake8 finds 
this is the only correct indentation, so I have no reason to complain.

Perhaps putting it on the preceding line would be better?



  reply	other threads:[~2021-02-19 12:05 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-02-16 17:16 [PATCH] iotests: Drop deprecated 'props' from object-add Alberto Garcia
2021-02-19 12:04 ` Max Reitz [this message]
2021-02-19 12:35   ` Alberto Garcia
2021-02-19 12:21 ` Kevin Wolf
2021-02-19 12:45   ` Alberto Garcia
2021-02-19 13:26     ` Kevin Wolf

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=ff22d21d-ccd8-77e5-1b4c-786e3df79400@redhat.com \
    --to=mreitz@redhat.com \
    --cc=berto@igalia.com \
    --cc=kwolf@redhat.com \
    --cc=qemu-block@nongnu.org \
    --cc=qemu-devel@nongnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).