qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [PATCH] qapi: Improve input_type_enum()'s error message


From: John Snow
Subject: Re: [PATCH] qapi: Improve input_type_enum()'s error message
Date: Tue, 26 Oct 2021 15:18:07 -0400



On Tue, Oct 12, 2021 at 8:10 AM Markus Armbruster <armbru@redhat.com> wrote:
Kevin Wolf <kwolf@redhat.com> writes:

> Am 11.10.2021 um 15:15 hat Markus Armbruster geschrieben:
>> The error message claims the parameter is invalid:
>>
>>     $ qemu-system-x86_64 -object qom-type=nonexistent
>>     qemu-system-x86_64: -object qom-type=nonexistent: Invalid parameter 'nonexistent'
>>
>> What's wrong is actually the *value* 'nonexistent'.  Improve the
>> message to
>>
>>     qemu-system-x86_64: -object qom-type=nonexistent: Parameter 'qom-type' does not accept value 'nonexistent'
>>
>> Signed-off-by: Markus Armbruster <armbru@redhat.com>
>> ---
>>  qapi/qapi-visit-core.c          | 3 ++-
>>  tests/unit/check-qom-proplist.c | 2 +-
>>  tests/qemu-iotests/049.out      | 6 +++---
>>  tests/qemu-iotests/206.out      | 2 +-
>>  tests/qemu-iotests/237.out      | 6 +++---
>>  tests/qemu-iotests/245          | 2 +-
>
> Good that you remembered to update iotests cases. I'm afraid there are
> two more that need an update.
>
> 287 contains these lines:
>
>     output=$(_make_test_img -o 'compression_type=zstd' 64M; _cleanup_test_img)
>     if echo "$output" | grep -q "Invalid parameter 'zstd'"; then
>         _notrun "ZSTD is disabled"
>     fi
>
> Instead of skipping the test case when zstd support is not compiled in,
> this test fails now.
>
> 308 contains a similar check for FUSE support and fails now when FUSE
> support is disabled.

287 passes for me.  I figure that's because I built with CONFIG_ZSTD.
308 I simply missed.

Thanks for your help!

This likely fixes https://gitlab.com/qemu-project/qemu/-/issues/608 and you could include that in your commit message if it isn't too late.

--js

reply via email to

[Prev in Thread] Current Thread [Next in Thread]