aboutsummaryrefslogtreecommitdiff
path: root/tests/qtest
diff options
context:
space:
mode:
Diffstat (limited to 'tests/qtest')
-rw-r--r--tests/qtest/migration-test.c48
-rw-r--r--tests/qtest/test-hmp.c6
-rw-r--r--tests/qtest/vhost-user-test.c8
3 files changed, 7 insertions, 55 deletions
diff --git a/tests/qtest/migration-test.c b/tests/qtest/migration-test.c
index f2142fb..3a711bb 100644
--- a/tests/qtest/migration-test.c
+++ b/tests/qtest/migration-test.c
@@ -658,53 +658,6 @@ static void test_migrate_end(QTestState *from, QTestState *to, bool test_dest)
cleanup("dest_serial");
}
-static void deprecated_set_downtime(QTestState *who, const double value)
-{
- QDict *rsp;
-
- rsp = qtest_qmp(who,
- "{ 'execute': 'migrate_set_downtime',"
- " 'arguments': { 'value': %f } }", value);
- g_assert(qdict_haskey(rsp, "return"));
- qobject_unref(rsp);
- migrate_check_parameter_int(who, "downtime-limit", value * 1000);
-}
-
-static void deprecated_set_speed(QTestState *who, long long value)
-{
- QDict *rsp;
-
- rsp = qtest_qmp(who, "{ 'execute': 'migrate_set_speed',"
- "'arguments': { 'value': %lld } }", value);
- g_assert(qdict_haskey(rsp, "return"));
- qobject_unref(rsp);
- migrate_check_parameter_int(who, "max-bandwidth", value);
-}
-
-static void deprecated_set_cache_size(QTestState *who, long long value)
-{
- QDict *rsp;
-
- rsp = qtest_qmp(who, "{ 'execute': 'migrate-set-cache-size',"
- "'arguments': { 'value': %lld } }", value);
- g_assert(qdict_haskey(rsp, "return"));
- qobject_unref(rsp);
- migrate_check_parameter_int(who, "xbzrle-cache-size", value);
-}
-
-static void test_deprecated(void)
-{
- QTestState *from;
-
- from = qtest_init("-machine none");
-
- deprecated_set_downtime(from, 0.12345);
- deprecated_set_speed(from, 12345);
- deprecated_set_cache_size(from, 4096);
-
- qtest_quit(from);
-}
-
static int migrate_postcopy_prepare(QTestState **from_ptr,
QTestState **to_ptr,
MigrateStart *args)
@@ -1486,7 +1439,6 @@ int main(int argc, char **argv)
qtest_add_func("/migration/postcopy/unix", test_postcopy);
qtest_add_func("/migration/postcopy/recovery", test_postcopy_recovery);
- qtest_add_func("/migration/deprecated", test_deprecated);
qtest_add_func("/migration/bad_dest", test_baddest);
qtest_add_func("/migration/precopy/unix", test_precopy_unix);
qtest_add_func("/migration/precopy/tcp", test_precopy_tcp);
diff --git a/tests/qtest/test-hmp.c b/tests/qtest/test-hmp.c
index 94a8023..413eb95 100644
--- a/tests/qtest/test-hmp.c
+++ b/tests/qtest/test-hmp.c
@@ -45,9 +45,9 @@ static const char *hmp_cmds[] = {
"log all",
"log none",
"memsave 0 4096 \"/dev/null\"",
- "migrate_set_cache_size 1",
- "migrate_set_downtime 1",
- "migrate_set_speed 1",
+ "migrate_set_parameter xbzrle_cache_size 1",
+ "migrate_set_parameter downtime_limit 1",
+ "migrate_set_parameter max_bandwidth 1",
"netdev_add user,id=net1",
"set_link net1 off",
"set_link net1 on",
diff --git a/tests/qtest/vhost-user-test.c b/tests/qtest/vhost-user-test.c
index 1a5f531..3d6337f 100644
--- a/tests/qtest/vhost-user-test.c
+++ b/tests/qtest/vhost-user-test.c
@@ -756,8 +756,8 @@ static void test_migrate(void *obj, void *arg, QGuestAllocator *alloc)
/* slow down migration to have time to fiddle with log */
/* TODO: qtest could learn to break on some places */
- rsp = qmp("{ 'execute': 'migrate_set_speed',"
- "'arguments': { 'value': 10 } }");
+ rsp = qmp("{ 'execute': 'migrate-set-parameters',"
+ "'arguments': { 'max-bandwidth': 10 } }");
g_assert(qdict_haskey(rsp, "return"));
qobject_unref(rsp);
@@ -776,8 +776,8 @@ static void test_migrate(void *obj, void *arg, QGuestAllocator *alloc)
munmap(log, size);
/* speed things up */
- rsp = qmp("{ 'execute': 'migrate_set_speed',"
- "'arguments': { 'value': 0 } }");
+ rsp = qmp("{ 'execute': 'migrate-set-parameters',"
+ "'arguments': { 'max-bandwidth': 0 } }");
g_assert(qdict_haskey(rsp, "return"));
qobject_unref(rsp);