[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[PULL 22/25] tests/acceptance/migration.py: Wait for both sides
From: |
Philippe Mathieu-Daudé |
Subject: |
[PULL 22/25] tests/acceptance/migration.py: Wait for both sides |
Date: |
Sun, 31 May 2020 18:38:43 +0200 |
From: "Dr. David Alan Gilbert" <dgilbert@redhat.com>
When the source finishes migration the destination will still be
receiving the data sent by the source, so it might not have quite
finished yet, so won't quite have reached 'completed'.
This lead to occasional asserts in the next few checks.
After the source has finished, check the destination as well.
(We can't just switch to checking the destination, because it doesn't
give a status until it has started receiving the migration).
Reported-by: Alex Bennée <alex.bennee@linaro.org>
Signed-off-by: Dr. David Alan Gilbert <dgilbert@redhat.com>
Tested-by: Alex Bennée <alex.bennee@linaro.org>
Reviewed-by: Philippe Mathieu-Daudé <philmd@redhat.com>
Message-Id: <20200528112404.121972-1-dgilbert@redhat.com>
Signed-off-by: Philippe Mathieu-Daudé <philmd@redhat.com>
---
tests/acceptance/migration.py | 4 ++++
1 file changed, 4 insertions(+)
diff --git a/tests/acceptance/migration.py b/tests/acceptance/migration.py
index 0365289cda..792639cb69 100644
--- a/tests/acceptance/migration.py
+++ b/tests/acceptance/migration.py
@@ -35,6 +35,10 @@ def assert_migration(self, src_vm, dst_vm):
timeout=self.timeout,
step=0.1,
args=(src_vm,))
+ wait.wait_for(self.migration_finished,
+ timeout=self.timeout,
+ step=0.1,
+ args=(dst_vm,))
self.assertEqual(src_vm.command('query-migrate')['status'],
'completed')
self.assertEqual(dst_vm.command('query-migrate')['status'],
'completed')
self.assertEqual(dst_vm.command('query-status')['status'], 'running')
--
2.21.3
- [PULL 12/25] python/qemu: remove Python2 style super() calls, (continued)
- [PULL 12/25] python/qemu: remove Python2 style super() calls, Philippe Mathieu-Daudé, 2020/05/31
- [PULL 13/25] python/qemu: fix socket.makefile() typing, Philippe Mathieu-Daudé, 2020/05/31
- [PULL 14/25] python/qemu: Adjust traceback typing, Philippe Mathieu-Daudé, 2020/05/31
- [PULL 15/25] python/qemu/qmp: use True/False for non/blocking modes, Philippe Mathieu-Daudé, 2020/05/31
- [PULL 16/25] python/qemu/qmp: assert sockfile is not None, Philippe Mathieu-Daudé, 2020/05/31
- [PULL 17/25] python/qemu/qtest: Check before accessing _qtest, Philippe Mathieu-Daudé, 2020/05/31
- [PULL 18/25] tests/vm: Pass --debug through for vm-boot-ssh, Philippe Mathieu-Daudé, 2020/05/31
- [PULL 19/25] tests/vm: Add ability to select QEMU from current build, Philippe Mathieu-Daudé, 2020/05/31
- [PULL 20/25] tests/vm: allow wait_ssh() to specify command, Philippe Mathieu-Daudé, 2020/05/31
- [PULL 21/25] tests/migration/guestperf: Use Python 3 interpreter, Philippe Mathieu-Daudé, 2020/05/31
- [PULL 22/25] tests/acceptance/migration.py: Wait for both sides,
Philippe Mathieu-Daudé <=
- [PULL 23/25] tests/acceptance: allow console interaction with specific VMs, Philippe Mathieu-Daudé, 2020/05/31
- [PULL 24/25] tests/acceptance: refactor boot_linux_console test to allow code reuse, Philippe Mathieu-Daudé, 2020/05/31
- [PULL 25/25] tests/acceptance: refactor boot_linux to allow code reuse, Philippe Mathieu-Daudé, 2020/05/31