[Qemu-devel] [PATCH for-2.12 v3 2/2] iotests: Update 186 after commit ac64273c66ab136c44043259162

Alberto Garcia posted 2 patches 7 years, 7 months ago
There is a newer version of this series
[Qemu-devel] [PATCH for-2.12 v3 2/2] iotests: Update 186 after commit ac64273c66ab136c44043259162
Posted by Alberto Garcia 7 years, 7 months ago
Signed-off-by: Alberto Garcia <berto@igalia.com>
Cc: Philippe Mathieu-Daudé <f4bug@amsat.org>
---
 tests/qemu-iotests/186.out | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/tests/qemu-iotests/186.out b/tests/qemu-iotests/186.out
index ec75c0fc60..5020162826 100644
--- a/tests/qemu-iotests/186.out
+++ b/tests/qemu-iotests/186.out
@@ -404,7 +404,7 @@ Testing: -drive if=floppy
 QEMU X.Y.Z monitor - type 'help' for more information
 (qemu) info block
 floppy0: [not inserted]
-    Attached to:      /machine/unattached/device[17]
+    Attached to:      /machine/unattached/device[13]
     Removable device: not locked, tray closed
 (qemu) quit
 
@@ -412,7 +412,7 @@ Testing: -drive if=floppy,driver=null-co
 QEMU X.Y.Z monitor - type 'help' for more information
 (qemu) info block
 floppy0 (NODE_NAME): null-co:// (null-co)
-    Attached to:      /machine/unattached/device[17]
+    Attached to:      /machine/unattached/device[13]
     Removable device: not locked, tray closed
     Cache mode:       writeback
 (qemu) quit
-- 
2.11.0


Re: [Qemu-devel] [PATCH for-2.12 v3 2/2] iotests: Update 186 after commit ac64273c66ab136c44043259162
Posted by Eric Blake 7 years, 7 months ago
On 03/22/2018 06:14 AM, Alberto Garcia wrote:
> Signed-off-by: Alberto Garcia <berto@igalia.com>
> Cc: Philippe Mathieu-Daudé <f4bug@amsat.org>
> ---
>   tests/qemu-iotests/186.out | 4 ++--
>   1 file changed, 2 insertions(+), 2 deletions(-)
> 
> diff --git a/tests/qemu-iotests/186.out b/tests/qemu-iotests/186.out
> index ec75c0fc60..5020162826 100644
> --- a/tests/qemu-iotests/186.out
> +++ b/tests/qemu-iotests/186.out
> @@ -404,7 +404,7 @@ Testing: -drive if=floppy
>   QEMU X.Y.Z monitor - type 'help' for more information
>   (qemu) info block
>   floppy0: [not inserted]
> -    Attached to:      /machine/unattached/device[17]
> +    Attached to:      /machine/unattached/device[13]

It looks like this name is quite flexible; would it not be better to 
enhance 186 to sed out the name (s/Attached to:.*/Attached to: PATH/) 
and then adjust the .out so that it is no longer sensitive to these 
types of internal renames?

-- 
Eric Blake, Principal Software Engineer
Red Hat, Inc.           +1-919-301-3266
Virtualization:  qemu.org | libvirt.org

Re: [Qemu-devel] [PATCH for-2.12 v3 2/2] iotests: Update 186 after commit ac64273c66ab136c44043259162
Posted by Alberto Garcia 7 years, 7 months ago
On Thu 22 Mar 2018 02:17:23 PM CET, Eric Blake wrote:
>> --- a/tests/qemu-iotests/186.out
>> +++ b/tests/qemu-iotests/186.out
>> @@ -404,7 +404,7 @@ Testing: -drive if=floppy
>>   QEMU X.Y.Z monitor - type 'help' for more information
>>   (qemu) info block
>>   floppy0: [not inserted]
>> -    Attached to:      /machine/unattached/device[17]
>> +    Attached to:      /machine/unattached/device[13]
>
> It looks like this name is quite flexible; would it not be better to
> enhance 186 to sed out the name (s/Attached to:.*/Attached to: PATH/)
> and then adjust the .out so that it is no longer sensitive to these
> types of internal renames?

That's a good idea, shall we hide the number only?  (i.e. leave
"/machine/unattached/device[INDEX]" or something like that), or can the
rest of the path also change?

Berto

Re: [Qemu-devel] [PATCH for-2.12 v3 2/2] iotests: Update 186 after commit ac64273c66ab136c44043259162
Posted by Eric Blake 7 years, 7 months ago
On 03/22/2018 08:42 AM, Alberto Garcia wrote:
> On Thu 22 Mar 2018 02:17:23 PM CET, Eric Blake wrote:
>>> --- a/tests/qemu-iotests/186.out
>>> +++ b/tests/qemu-iotests/186.out
>>> @@ -404,7 +404,7 @@ Testing: -drive if=floppy
>>>    QEMU X.Y.Z monitor - type 'help' for more information
>>>    (qemu) info block
>>>    floppy0: [not inserted]
>>> -    Attached to:      /machine/unattached/device[17]
>>> +    Attached to:      /machine/unattached/device[13]
>>
>> It looks like this name is quite flexible; would it not be better to
>> enhance 186 to sed out the name (s/Attached to:.*/Attached to: PATH/)
>> and then adjust the .out so that it is no longer sensitive to these
>> types of internal renames?
> 
> That's a good idea, shall we hide the number only?  (i.e. leave
> "/machine/unattached/device[INDEX]" or something like that), or can the
> rest of the path also change?

I don't see the value in knowing whether the device is unattached, or if 
a future attaches it somewhere, so changing the entire thing to PATH 
seems reasonable, rather than trying to just focus on the index.  (That 
is, the sed expression I mentioned is sufficient)

-- 
Eric Blake, Principal Software Engineer
Red Hat, Inc.           +1-919-301-3266
Virtualization:  qemu.org | libvirt.org