[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[RFC PATCH v3 26/28] target/avocado: Pass parameters to migration test o
From: |
Fabiano Rosas |
Subject: |
[RFC PATCH v3 26/28] target/avocado: Pass parameters to migration test on aarch64 |
Date: |
Fri, 13 Jan 2023 11:04:17 -0300 |
The migration tests are currently broken for an aarch64 host because
the tests pass no 'machine' and 'cpu' options on the QEMU command
line. Most other architectures define a default value in QEMU for
these options, but arm does not.
Add these options to the test class in case the test is being executed
in an aarch64 host.
Signed-off-by: Fabiano Rosas <farosas@suse.de>
---
Don't we want to run migration tests for all the built targets? A
cleaner approach would be to just subclass Migration for each
archictecture like in boot_linux.py.
---
tests/avocado/migration.py | 11 ++++++++++-
1 file changed, 10 insertions(+), 1 deletion(-)
diff --git a/tests/avocado/migration.py b/tests/avocado/migration.py
index 4b25680c50..f1c43622c0 100644
--- a/tests/avocado/migration.py
+++ b/tests/avocado/migration.py
@@ -11,6 +11,8 @@
import tempfile
+import os
+
from avocado_qemu import QemuSystemTest
from avocado import skipUnless
@@ -26,6 +28,14 @@ class Migration(QemuSystemTest):
timeout = 10
+ def setUp(self):
+ super().setUp()
+
+ arch = os.uname()[4]
+ if arch == 'aarch64':
+ self.machine = 'virt'
+ self.cpu = 'max'
+
@staticmethod
def migration_finished(vm):
return vm.command('query-migrate')['status'] in ('completed', 'failed')
@@ -62,7 +72,6 @@ def _get_free_port(self):
self.cancel('Failed to find a free port')
return port
-
def test_migration_with_tcp_localhost(self):
dest_uri = 'tcp:localhost:%u' % self._get_free_port()
self.do_migrate(dest_uri)
--
2.35.3
- [RFC PATCH v3 22/28] tests/qtest: Restrict bcm2835-dma-test to CONFIG_RASPI, (continued)
- [RFC PATCH v3 22/28] tests/qtest: Restrict bcm2835-dma-test to CONFIG_RASPI, Fabiano Rosas, 2023/01/13
- [RFC PATCH v3 23/28] tests/tcg: Do not build/run TCG tests if TCG is disabled, Fabiano Rosas, 2023/01/13
- [RFC PATCH v3 24/28] tests/avocado: Skip tests that require a missing accelerator, Fabiano Rosas, 2023/01/13
- [RFC PATCH v3 25/28] tests/avocado: Tag TCG tests with accel:tcg, Fabiano Rosas, 2023/01/13
- [RFC PATCH v3 26/28] target/avocado: Pass parameters to migration test on aarch64,
Fabiano Rosas <=
- [RFC PATCH v3 27/28] arm/Kconfig: Always select SEMIHOSTING when TCG is present, Fabiano Rosas, 2023/01/13
- [RFC PATCH v3 28/28] arm/Kconfig: Do not build TCG-only boards on a KVM-only build, Fabiano Rosas, 2023/01/13
- Re: [RFC PATCH v3 00/28] target/arm: Allow CONFIG_TCG=n builds, Philippe Mathieu-Daudé, 2023/01/18