[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Qemu-devel] [RFC 17/18] validator.py script
From: |
Markus Armbruster |
Subject: |
Re: [Qemu-devel] [RFC 17/18] validator.py script |
Date: |
Wed, 18 Apr 2018 08:58:00 +0200 |
User-agent: |
Gnus/5.13 (Gnus v5.13) Emacs/25.3 (gnu/linux) |
Eduardo Habkost <address@hidden> writes:
> On Tue, Apr 17, 2018 at 02:01:53PM +0200, Markus Armbruster wrote:
>> Eduardo Habkost <address@hidden> writes:
[...]
>> > + command-line: '$QEMU -nodefaults -machine none'
>> > + monitor-commands:
>> > + - qmp:
>> > + - execute: qom-list-types
>> > + arguments:
>> > + implements: 'device'
>> > + abstract: true
>> > + - hmp: 'device_add help'
[...]
>> > +monitor-commands
>> > +~~~~~~~~~~~~~~~~
>> > +
>> > +Mapping or list-of-mappings containing monitor commands to run.
http://yaml.org/spec/1.2/spec.html talks about mappings and sequences.
Recommend to say "sequence" rather than "list".
I can't see how sequences come into play. Your example's
monitor-command is a mapping, not a sequence of mappings. Am I
confused?
>> > The key
>> > on each
>> > +item can be ``hmp`` or ``qmp``. The value on each entry can be a string,
>> > +mapping, or list.
>> > +
>> > +Default: None.
[...]
>> Can I do
>>
>> monitor-commands:
>> - qmp:
>> - execute: eins
>> - hmp: zwei
>> - qmp:
>> - execute: drei
>>
>> to execute eins, zwei, drei in this order?
>
> Yes, it can. See the test specification examples.
I asked because the YAML spec I quoted above says mappings are unordered
and must be unique. My example violates "unique", and your "yes, it
can" violates "unordered".
[...]