[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[PATCH 5/8] tests: Add migration precopy initial data capability test
|
From: |
Avihai Horon |
|
Subject: |
[PATCH 5/8] tests: Add migration precopy initial data capability test |
|
Date: |
Mon, 1 May 2023 17:01:38 +0300 |
Add migration precopy initial data capability test. The test runs
without migration users that support this capability, but is still
useful to make sure it didn't break anything.
Signed-off-by: Avihai Horon <avihaih@nvidia.com>
---
tests/qtest/migration-test.c | 23 +++++++++++++++++++++++
1 file changed, 23 insertions(+)
diff --git a/tests/qtest/migration-test.c b/tests/qtest/migration-test.c
index 60dd53d3ec..71d30bd330 100644
--- a/tests/qtest/migration-test.c
+++ b/tests/qtest/migration-test.c
@@ -1533,6 +1533,25 @@ static void test_precopy_tcp_plain(void)
test_precopy_common(&args);
}
+static void *test_migrate_initial_data_start(QTestState *from, QTestState *to)
+{
+
+ migrate_set_capability(from, "return-path", true);
+ migrate_set_capability(from, "precopy-initial-data", true);
+
+ return NULL;
+}
+
+static void test_precopy_tcp_initial_data(void)
+{
+ MigrateCommon args = {
+ .listen_uri = "tcp:127.0.0.1:0",
+ .start_hook = test_migrate_initial_data_start,
+ };
+
+ test_precopy_common(&args);
+}
+
#ifdef CONFIG_GNUTLS
static void test_precopy_tcp_tls_psk_match(void)
{
@@ -2557,6 +2576,10 @@ int main(int argc, char **argv)
#endif /* CONFIG_GNUTLS */
qtest_add_func("/migration/precopy/tcp/plain", test_precopy_tcp_plain);
+
+ qtest_add_func("/migration/precopy/tcp/plain/precopy-initial-data",
+ test_precopy_tcp_initial_data);
+
#ifdef CONFIG_GNUTLS
qtest_add_func("/migration/precopy/tcp/tls/psk/match",
test_precopy_tcp_tls_psk_match);
--
2.26.3
- Re: [PATCH 2/8] migration: Add precopy initial data handshake, (continued)
- [PATCH 5/8] tests: Add migration precopy initial data capability test,
Avihai Horon <=
- [PATCH 6/8] vfio/migration: Refactor vfio_save_block() to return saved data size, Avihai Horon, 2023/05/01
- [PATCH 4/8] migration: Enable precopy initial data capability, Avihai Horon, 2023/05/01
- [PATCH 7/8] vfio/migration: Add VFIO migration pre-copy support, Avihai Horon, 2023/05/01
- [PATCH 8/8] vfio/migration: Add support for precopy initial data capability, Avihai Horon, 2023/05/01
- Re: [PATCH 0/8] migration: Add precopy initial data capability and VFIO precopy support, Peter Xu, 2023/05/02