Skip to contentSkip to conversation

tests/avocado: configure acpi-bits to use avocado timeout

PATCH In review John Snow 4 participants 14 messages Nov 15, 2022 – Nov 18, 2022

lore
Share & tools
lore

John Snow

author
#0 lore raw

PATCH 1/1 tests/avocado: configure acpi-bits to use avocado timeout

Instead of using a hardcoded timeout, just rely on Avocado's built-in test case timeout. This helps avoid timeout issues on machines where 60 seconds is not sufficient.

---
 tests/avocado/acpi-bits.py | 10 ++--------
 1 file changed, 2 insertions(+), 8 deletions(-)
tests/avocado/acpi-bits.py +2 -8
index 8745a58a766..ac13e22dc93 100644
@@ -385,12 +385,6 @@ def test_acpi_smbios_bits(self):
         self._vm.launch()
         # biosbits has been configured to run all the specified test suites
         # in batch mode and then automatically initiate a vm shutdown.
-        # sleep for maximum of one minute
-        max_sleep_time = time.monotonic() + 60
-        while self._vm.is_running() and time.monotonic() < max_sleep_time:
-            time.sleep(1)
-
-        self.assertFalse(time.monotonic() > max_sleep_time,
-                         'The VM seems to have failed to shutdown in time')
-
+        # Rely on avocado's unit test timeout.
+        self._vm.wait(timeout=None)
         self.parse_log()
Signature · 1 line
2.37.3
#1 lore raw
Quoted 15 lines · John Snow

Instead of using a hardcoded timeout, just rely on Avocado's built-in test case timeout. This helps avoid timeout issues on machines where 60 seconds is not sufficient.

---
 tests/avocado/acpi-bits.py | 10 ++--------
 1 file changed, 2 insertions(+), 8 deletions(-)
tests/avocado/acpi-bits.py +0 -0
index 8745a58a766..ac13e22dc93 100644
@@ -385,12 +385,6 @@ def test_acpi_smbios_bits(self):
         self._vm.launch()

tests/avocado/acpi-bits.py def test_acpi_smbios_bits(self): · line 395

Quoted 10 lines
tests/avocado/acpi-bits.py +0 -8
         # biosbits has been configured to run all the specified test suites
         # in batch mode and then automatically initiate a vm shutdown.
-        # sleep for maximum of one minute
-        max_sleep_time = time.monotonic() + 60
-        while self._vm.is_running() and time.monotonic() < max_sleep_time:
-            time.sleep(1)
-
-        self.assertFalse(time.monotonic() > max_sleep_time,
-                         'The VM seems to have failed to shutdown in time')
-

We might want some wait for consoles as well depending on what is output during the run.

Quoted 3 lines
tests/avocado/acpi-bits.py +2 -0
+        # Rely on avocado's unit test timeout.
+        self._vm.wait(timeout=None)
         self.parse_log()
Signature · 1 line
Alex Bennée
author
#2 lore raw
Quoted 29 lines · Alex Bennée
Quoted 14 lines · John Snow

Instead of using a hardcoded timeout, just rely on Avocado's built-in test case timeout. This helps avoid timeout issues on machines where 60 seconds is not sufficient.

---
 tests/avocado/acpi-bits.py | 10 ++--------
 1 file changed, 2 insertions(+), 8 deletions(-)
tests/avocado/acpi-bits.py +0 -0
index 8745a58a766..ac13e22dc93 100644

tests/avocado/acpi-bits.py def test_acpi_smbios_bits(self): · line 386

Quoted 2 lines
tests/avocado/acpi-bits.py +0 -0
@@ -385,12 +385,6 @@ def test_acpi_smbios_bits(self):
         self._vm.launch()
         # biosbits has been configured to run all the specified test

suites

tests/avocado/acpi-bits.py def test_acpi_smbios_bits(self):

Quoted 4 lines
tests/avocado/acpi-bits.py +0 -3
         # in batch mode and then automatically initiate a vm shutdown.
-        # sleep for maximum of one minute
-        max_sleep_time = time.monotonic() + 60
-        while self._vm.is_running() and time.monotonic() <

max_sleep_time:

tests/avocado/acpi-bits.py def test_acpi_smbios_bits(self):

Quoted 4 lines
tests/avocado/acpi-bits.py +0 -4
-            time.sleep(1)
-
-        self.assertFalse(time.monotonic() > max_sleep_time,
-                         'The VM seems to have failed to shutdown in
Quoted 6 lines

time')

tests/avocado/acpi-bits.py def test_acpi_smbios_bits(self): · line 395

Quoted 1 line
tests/avocado/acpi-bits.py +0 -1
-

We might want some wait for consoles as well depending on what is output during the run.

Ah! there's the catch I was forgetting. I subbed this in and it appeared to work, so I thought I was home free.

OK, back to the drawing board...

Quoted 10 lines

tests/avocado/acpi-bits.py def test_acpi_smbios_bits(self): · line 390

Quoted 4 lines
tests/avocado/acpi-bits.py +2 -0
+        # Rely on avocado's unit test timeout.
+        self._vm.wait(timeout=None)
         self.parse_log()

--
Alex Bennée

#3 lore raw
In reply to Alex Bennée
Quoted 24 lines · Alex Bennée
Quoted 20 lines · John Snow

Instead of using a hardcoded timeout, just rely on Avocado's built-in test case timeout. This helps avoid timeout issues on machines where 60 seconds is not sufficient.

---
 tests/avocado/acpi-bits.py | 10 ++--------
 1 file changed, 2 insertions(+), 8 deletions(-)
tests/avocado/acpi-bits.py +0 -3
index 8745a58a766..ac13e22dc93 100644
@@ -385,12 +385,6 @@ def test_acpi_smbios_bits(self):
         self._vm.launch()
         # biosbits has been configured to run all the specified test suites
         # in batch mode and then automatically initiate a vm shutdown.
-        # sleep for maximum of one minute
-        max_sleep_time = time.monotonic() + 60
-        while self._vm.is_running() and time.monotonic() < max_sleep_time:
Quoted 8 lines

tests/avocado/acpi-bits.py def test_acpi_smbios_bits(self): · line 395

Quoted 5 lines
tests/avocado/acpi-bits.py +0 -5
-            time.sleep(1)
-
-        self.assertFalse(time.monotonic() > max_sleep_time,
-                         'The VM seems to have failed to shutdown in time')
-

We might want some wait for consoles as well depending on what is output during the run.

actually I think you won't get anything on the console since grub is not configured to use the serial console. I tried "-serial stdio" a while back without any output.

Quoted 9 lines

tests/avocado/acpi-bits.py def test_acpi_smbios_bits(self): · line 390

Quoted 5 lines
tests/avocado/acpi-bits.py +2 -0
+        # Rely on avocado's unit test timeout.
+        self._vm.wait(timeout=None)
         self.parse_log()

--
Alex Bennée

#4 lore raw
Quoted 34 lines · Ani Sinha
Quoted 24 lines · Alex Bennée
Quoted 20 lines · John Snow

Instead of using a hardcoded timeout, just rely on Avocado's built-in test case timeout. This helps avoid timeout issues on machines where 60 seconds is not sufficient.

---
 tests/avocado/acpi-bits.py | 10 ++--------
 1 file changed, 2 insertions(+), 8 deletions(-)
tests/avocado/acpi-bits.py +0 -3
index 8745a58a766..ac13e22dc93 100644
@@ -385,12 +385,6 @@ def test_acpi_smbios_bits(self):
         self._vm.launch()
         # biosbits has been configured to run all the specified test suites
         # in batch mode and then automatically initiate a vm shutdown.
-        # sleep for maximum of one minute
-        max_sleep_time = time.monotonic() + 60
-        while self._vm.is_running() and time.monotonic() < max_sleep_time:
Quoted 8 lines

tests/avocado/acpi-bits.py def test_acpi_smbios_bits(self): · line 395

Quoted 5 lines
tests/avocado/acpi-bits.py +0 -5
-            time.sleep(1)
-
-        self.assertFalse(time.monotonic() > max_sleep_time,
-                         'The VM seems to have failed to shutdown in time')
-

We might want some wait for consoles as well depending on what is output during the run.

Quoted 3 lines

actually I think you won't get anything on the console since grub is not configured to use the serial console. I tried "-serial stdio" a while back without any output.

Grub is certainly capable of serial output but I think the grub.cfg needs changes to support that. It would definitely be an improvement if we could enable serial output because currently the test is totally mute while running which is unlike every other test in avocado.

Quoted 10 lines
Quoted 10 lines

tests/avocado/acpi-bits.py def test_acpi_smbios_bits(self): · line 390

Quoted 6 lines
tests/avocado/acpi-bits.py +2 -0
+        # Rely on avocado's unit test timeout.
+        self._vm.wait(timeout=None)
         self.parse_log()

--
Alex Bennée

Signature · 1 line
Alex Bennée
#5 lore raw
Quoted 38 lines · Alex Bennée
Quoted 34 lines · Ani Sinha
Quoted 32 lines · Alex Bennée
Quoted 15 lines · John Snow

Instead of using a hardcoded timeout, just rely on Avocado's built-in test case timeout. This helps avoid timeout issues on machines where 60 seconds is not sufficient.

---
 tests/avocado/acpi-bits.py | 10 ++--------
 1 file changed, 2 insertions(+), 8 deletions(-)
tests/avocado/acpi-bits.py +0 -0
index 8745a58a766..ac13e22dc93 100644
@@ -385,12 +385,6 @@ def test_acpi_smbios_bits(self):
         self._vm.launch()

tests/avocado/acpi-bits.py def test_acpi_smbios_bits(self): · line 395

Quoted 10 lines
tests/avocado/acpi-bits.py +0 -8
         # biosbits has been configured to run all the specified test suites
         # in batch mode and then automatically initiate a vm shutdown.
-        # sleep for maximum of one minute
-        max_sleep_time = time.monotonic() + 60
-        while self._vm.is_running() and time.monotonic() < max_sleep_time:
-            time.sleep(1)
-
-        self.assertFalse(time.monotonic() > max_sleep_time,
-                         'The VM seems to have failed to shutdown in time')
-

We might want some wait for consoles as well depending on what is output during the run.

Quoted 8 lines
Quoted 3 lines

actually I think you won't get anything on the console since grub is not configured to use the serial console. I tried "-serial stdio" a while back without any output.

Grub is certainly capable of serial output but I think the grub.cfg needs changes to support that. It would definitely be an improvement if we could enable serial output because currently the test is totally mute while running which is unlike every other test in avocado.

sounds reasonable. bits seems to have its own way to set up grub serial port redirect and I tried something quickly but it didn't quite work. Need to spend more time looking at it.

#6 lore raw
Quoted 44 lines · Ani Sinha
Quoted 42 lines · Alex Bennée
Quoted 37 lines · Ani Sinha
Quoted 24 lines · Alex Bennée
Quoted 20 lines · John Snow

Instead of using a hardcoded timeout, just rely on Avocado's built-in test case timeout. This helps avoid timeout issues on machines where 60 seconds is not sufficient.

---
 tests/avocado/acpi-bits.py | 10 ++--------
 1 file changed, 2 insertions(+), 8 deletions(-)
tests/avocado/acpi-bits.py +0 -3
index 8745a58a766..ac13e22dc93 100644
@@ -385,12 +385,6 @@ def test_acpi_smbios_bits(self):
         self._vm.launch()
         # biosbits has been configured to run all the specified test suites
         # in batch mode and then automatically initiate a vm shutdown.
-        # sleep for maximum of one minute
-        max_sleep_time = time.monotonic() + 60
-        while self._vm.is_running() and time.monotonic() < max_sleep_time:
Quoted 8 lines

tests/avocado/acpi-bits.py def test_acpi_smbios_bits(self): · line 395

Quoted 5 lines
tests/avocado/acpi-bits.py +0 -5
-            time.sleep(1)
-
-        self.assertFalse(time.monotonic() > max_sleep_time,
-                         'The VM seems to have failed to shutdown in time')
-

We might want some wait for consoles as well depending on what is output during the run.

actually I think you won't get anything on the console since grub is not configured to use the serial console. I tried "-serial stdio" a while back without any output.

Quoted 8 lines
Quoted 4 lines

Grub is certainly capable of serial output but I think the grub.cfg needs changes to support that. It would definitely be an improvement if we could enable serial output because currently the test is totally mute while running which is unlike every other test in avocado.

sounds reasonable. bits seems to have its own way to set up grub serial port redirect and I tried something quickly but it didn't quite work. Need to spend more time looking at it.

just when I wrote this, it seems my hack finally worked! Will need more testing before pushing.

commit 58513f19ac7b537da0769a732ff0d93d6d93d3b0 (HEAD -> qemu-bits)

Author: Ani Sinha <[email protected]>
Date:   Wed Nov 16 17:37:51 2022 +0530

serial port redirection test

python/init.py +1 -1
index 8fde344..1e36d51 100644
@@ -85,7 +85,7 @@ def early_init():
         except Exception as e:
             print "Error parsing Serial Port Console Redirect (SPCR) table:"
             print e
-
+    serial_cmd = "serial --speed=115200 --unit=0 --word=8 --parity=no --stop=1"
     with import_annotation("os"):
         import os
     with init_annotation("os"):
Reviewed-by on v1 1/1
#7 lore raw
In reply to John Snow
Quoted 6 lines · John Snow

Instead of using a hardcoded timeout, just rely on Avocado's built-in test case timeout. This helps avoid timeout issues on machines where 60 seconds is not sufficient.

Quoted 12 lines
---
 tests/avocado/acpi-bits.py | 10 ++--------
 1 file changed, 2 insertions(+), 8 deletions(-)
tests/avocado/acpi-bits.py +0 -0
index 8745a58a766..ac13e22dc93 100644
@@ -385,12 +385,6 @@ def test_acpi_smbios_bits(self):
         self._vm.launch()
         # biosbits has been configured to run all the specified test suites
         # in batch mode and then automatically initiate a vm shutdown.

tests/avocado/acpi-bits.py def test_acpi_smbios_bits(self): · line 389

Quoted 10 lines
tests/avocado/acpi-bits.py +2 -8
-        # sleep for maximum of one minute
-        max_sleep_time = time.monotonic() + 60
-        while self._vm.is_running() and time.monotonic() < max_sleep_time:
-            time.sleep(1)
-
-        self.assertFalse(time.monotonic() > max_sleep_time,
-                         'The VM seems to have failed to shutdown in time')
-
+        # Rely on avocado's unit test timeout.
+        self._vm.wait(timeout=None)

I think this is fine. This just waits until the VM is shutdown on its own and relies on the avocado framework to timeout if it doesn't. We do not need to look into the console. The test issues a shutdown from the VM itself once its done with the batch operations.

Quoted 4 lines
tests/avocado/acpi-bits.py +0 -1
         self.parse_log()
--

2.37.3

author
#8 lore raw
Quoted 10 lines · Ani Sinha
Quoted 6 lines · John Snow

Instead of using a hardcoded timeout, just rely on Avocado's built-in test case timeout. This helps avoid timeout issues on machines where 60 seconds is not sufficient.

Alex's critique is valid, though: the way vm.wait() works is to immediately terminate the serial console connection as it prepares for the VM to shut down. I forgot about this.

(For historical reasons, it does this to avoid deadlocks when the pipe fills.)

I think we definitely do want to make sure we watch the console *while* we wait for it to shut down, which is not a feature QEMUMachine really offers right now in a meaningful way.

I need to make some more drastic changes to machine.py, but in the meantime I can revise this patch to do something a bit smarter so we get console logging while we wait. This is a use case worth supporting.

(Thanks for writing new and interesting tests!)

Quoted 22 lines

tests/avocado/acpi-bits.py def test_acpi_smbios_bits(self): · line 386

Quoted 11 lines
---
 tests/avocado/acpi-bits.py | 10 ++--------
 1 file changed, 2 insertions(+), 8 deletions(-)
tests/avocado/acpi-bits.py +0 -0
index 8745a58a766..ac13e22dc93 100644
@@ -385,12 +385,6 @@ def test_acpi_smbios_bits(self):
         self._vm.launch()
         # biosbits has been configured to run all the specified test

suites

tests/avocado/acpi-bits.py def test_acpi_smbios_bits(self):

Quoted 4 lines
tests/avocado/acpi-bits.py +0 -3
         # in batch mode and then automatically initiate a vm shutdown.
-        # sleep for maximum of one minute
-        max_sleep_time = time.monotonic() + 60
-        while self._vm.is_running() and time.monotonic() <

max_sleep_time:

tests/avocado/acpi-bits.py def test_acpi_smbios_bits(self):

Quoted 4 lines
tests/avocado/acpi-bits.py +0 -4
-            time.sleep(1)
-
-        self.assertFalse(time.monotonic() > max_sleep_time,
-                         'The VM seems to have failed to shutdown in

time')

Quoted 8 lines

tests/avocado/acpi-bits.py def test_acpi_smbios_bits(self): · line 389

Quoted 3 lines
tests/avocado/acpi-bits.py +2 -1
-
+        # Rely on avocado's unit test timeout.
+        self._vm.wait(timeout=None)

I think this is fine. This just waits until the VM is shutdown on its own and relies on the avocado framework to timeout if it doesn't. We do not need to look into the console. The test issues a shutdown from the VM itself once its done with the batch operations.

Still, if it fails, we want to see the output, right? It's very frustrating if it doesn't, especially in an automated pipeline.

Quoted 6 lines
Quoted 4 lines
tests/avocado/acpi-bits.py +0 -1
         self.parse_log()
--

2.37.3

#9 lore raw
Quoted 19 lines · John Snow
Quoted 10 lines · Ani Sinha
Quoted 6 lines · John Snow

Instead of using a hardcoded timeout, just rely on Avocado's built-in test case timeout. This helps avoid timeout issues on machines where 60 seconds is not sufficient.

Alex's critique is valid, though: the way vm.wait() works is to immediately terminate the serial console connection as it prepares for the VM to shut down. I forgot about this.

Quoted 7 lines

(For historical reasons, it does this to avoid deadlocks when the pipe fills.)

I think we definitely do want to make sure we watch the console *while* we wait for it to shut down, which is not a feature QEMUMachine really offers right now in a meaningful way.

Maybe we can push your current patch while we consider these console logging enhancements for the next release window. Console logging woikd require some changes in bits and some more testing. I'm not sure if I'll have time for it immediately at present.

Quoted 49 lines

I need to make some more drastic changes to machine.py, but in the meantime I can revise this patch to do something a bit smarter so we get console logging while we wait. This is a use case worth supporting.

(Thanks for writing new and interesting tests!)

Quoted 22 lines

tests/avocado/acpi-bits.py def test_acpi_smbios_bits(self): · line 386

Quoted 11 lines
---
 tests/avocado/acpi-bits.py | 10 ++--------
 1 file changed, 2 insertions(+), 8 deletions(-)
tests/avocado/acpi-bits.py +0 -0
index 8745a58a766..ac13e22dc93 100644
@@ -385,12 +385,6 @@ def test_acpi_smbios_bits(self):
         self._vm.launch()
         # biosbits has been configured to run all the specified test

suites

tests/avocado/acpi-bits.py def test_acpi_smbios_bits(self):

Quoted 4 lines
tests/avocado/acpi-bits.py +0 -3
         # in batch mode and then automatically initiate a vm shutdown.
-        # sleep for maximum of one minute
-        max_sleep_time = time.monotonic() + 60
-        while self._vm.is_running() and time.monotonic() <

max_sleep_time:

tests/avocado/acpi-bits.py def test_acpi_smbios_bits(self):

Quoted 4 lines
tests/avocado/acpi-bits.py +0 -4
-            time.sleep(1)
-
-        self.assertFalse(time.monotonic() > max_sleep_time,
-                         'The VM seems to have failed to shutdown in

time')

Quoted 8 lines

tests/avocado/acpi-bits.py def test_acpi_smbios_bits(self): · line 389

Quoted 3 lines
tests/avocado/acpi-bits.py +2 -1
-
+        # Rely on avocado's unit test timeout.
+        self._vm.wait(timeout=None)

I think this is fine. This just waits until the VM is shutdown on its own and relies on the avocado framework to timeout if it doesn't. We do not need to look into the console. The test issues a shutdown from the VM itself once its done with the batch operations.

Still, if it fails, we want to see the output, right? It's very frustrating if it doesn't, especially in an automated pipeline.

Quoted 6 lines
Quoted 4 lines
tests/avocado/acpi-bits.py +0 -1
         self.parse_log()
--

2.37.3

#10 lore raw
Quoted 20 lines · Ani Sinha
Quoted 16 lines · John Snow
Quoted 10 lines · Ani Sinha
Quoted 6 lines · John Snow

Instead of using a hardcoded timeout, just rely on Avocado's built-in test case timeout. This helps avoid timeout issues on machines where 60 seconds is not sufficient.

Quoted 13 lines
Quoted 5 lines

Alex's critique is valid, though: the way vm.wait() works is to immediately terminate the serial console connection as it prepares for the VM to shut down. I forgot about this.

(For historical reasons, it does this to avoid deadlocks when the pipe fills.)

I think we definitely do want to make sure we watch the console *while* we wait for it to shut down, which is not a feature QEMUMachine really offers right now in a meaningful way.

Maybe we can push your current patch while we consider these console logging enhancements for the next release window. Console logging woikd require some changes in bits and some more testing. I'm not sure if I'll have time for it immediately at present.

Quoted 4 lines

I need to make some more drastic changes to machine.py, but in the meantime I can revise this patch to do something a bit smarter so we get console logging while we wait. This is a use case worth supporting.

(Thanks for writing new and interesting tests!)

Spoke to John on IRC. Seems this patch using vm.wait() is safe for this release as I do not use the console o/p in the test and do not call vm.set_console().
When we enable the console output, some additional work will need to be done for the QemuMachine library to make sure we avoid races when we call vm.wait() with _early_cleanup().

Quoted 39 lines
Quoted 39 lines
Quoted 21 lines
Quoted 21 lines

---
 tests/avocado/acpi-bits.py | 10 ++--------
 1 file changed, 2 insertions(+), 8 deletions(-)
tests/avocado/acpi-bits.py +0 -7
index 8745a58a766..ac13e22dc93 100644
@@ -385,12 +385,6 @@ def test_acpi_smbios_bits(self):
         self._vm.launch()
         # biosbits has been configured to run all the specified test suites
         # in batch mode and then automatically initiate a vm shutdown.
-        # sleep for maximum of one minute
-        max_sleep_time = time.monotonic() + 60
-        while self._vm.is_running() and time.monotonic() < max_sleep_time:
-            time.sleep(1)
-
-        self.assertFalse(time.monotonic() > max_sleep_time,
-                         'The VM seems to have failed to shutdown in time')
Quoted 8 lines

tests/avocado/acpi-bits.py def test_acpi_smbios_bits(self): · line 389

Quoted 3 lines
tests/avocado/acpi-bits.py +2 -1
-
+        # Rely on avocado's unit test timeout.
+        self._vm.wait(timeout=None)

I think this is fine. This just waits until the VM is shutdown on its own and relies on the avocado framework to timeout if it doesn't. We do not need to look into the console. The test issues a shutdown from the VM itself once its done with the batch operations.

Still, if it fails, we want to see the output, right? It's very frustrating if it doesn't, especially in an automated pipeline.

Quoted 6 lines
Quoted 5 lines
tests/avocado/acpi-bits.py +0 -1
         self.parse_log()
--

2.37.3

#11 lore raw
In reply to Ani Sinha
Quoted 14 lines · Ani Sinha
Quoted 6 lines · John Snow

Instead of using a hardcoded timeout, just rely on Avocado's built-in test case timeout. This helps avoid timeout issues on machines where 60 seconds is not sufficient.

Quoted 3 lines
---
 tests/avocado/acpi-bits.py | 10 ++--------
 1 file changed, 2 insertions(+), 8 deletions(-)

Thomas, since you are picking up my other patch, maybe you want to also pick this one up as well if you have not sent out your PR already?

Quoted 29 lines
Quoted 9 lines
tests/avocado/acpi-bits.py +0 -0
index 8745a58a766..ac13e22dc93 100644
@@ -385,12 +385,6 @@ def test_acpi_smbios_bits(self):
         self._vm.launch()
         # biosbits has been configured to run all the specified test suites
         # in batch mode and then automatically initiate a vm shutdown.

tests/avocado/acpi-bits.py def test_acpi_smbios_bits(self): · line 389

Quoted 10 lines
tests/avocado/acpi-bits.py +2 -8
-        # sleep for maximum of one minute
-        max_sleep_time = time.monotonic() + 60
-        while self._vm.is_running() and time.monotonic() < max_sleep_time:
-            time.sleep(1)
-
-        self.assertFalse(time.monotonic() > max_sleep_time,
-                         'The VM seems to have failed to shutdown in time')
-
+        # Rely on avocado's unit test timeout.
+        self._vm.wait(timeout=None)

I think this is fine. This just waits until the VM is shutdown on its own and relies on the avocado framework to timeout if it doesn't. We do not need to look into the console. The test issues a shutdown from the VM itself once its done with the batch operations.

Quoted 4 lines
tests/avocado/acpi-bits.py +0 -1
         self.parse_log()
--

2.37.3

#12 lore raw
Quoted 12 lines · Ani Sinha
Quoted 11 lines · Ani Sinha
Quoted 6 lines · John Snow

Instead of using a hardcoded timeout, just rely on Avocado's built-in test case timeout. This helps avoid timeout issues on machines where 60 seconds is not sufficient.

Quoted 7 lines
Quoted 3 lines
Quoted 3 lines
---
  tests/avocado/acpi-bits.py | 10 ++--------
  1 file changed, 2 insertions(+), 8 deletions(-)

Thomas, since you are picking up my other patch, maybe you want to also pick this one up as well if you have not sent out your PR already?

Sorry, too late, it's already merged:

https://gitlab.com/qemu-project/qemu/-/commit/1b7a07c4414323d985e89c4e7

Thomas

#13 lore raw
Quoted 18 lines · Thomas Huth
Quoted 16 lines · Ani Sinha
Quoted 14 lines · Ani Sinha
Quoted 6 lines · John Snow

Instead of using a hardcoded timeout, just rely on Avocado's built-in test case timeout. This helps avoid timeout issues on machines where 60 seconds is not sufficient.

Quoted 3 lines
---
  tests/avocado/acpi-bits.py | 10 ++--------
  1 file changed, 2 insertions(+), 8 deletions(-)
Quoted 7 lines
Quoted 3 lines

Thomas, since you are picking up my other patch, maybe you want to also pick this one up as well if you have not sent out your PR already?

Sorry, too late, it's already merged:

https://gitlab.com/qemu-project/qemu/-/commit/1b7a07c4414323d985e89c4e7

Ok if you generate another PR with simple misc fixes, please let me know.