tests/qmp-cmd-test: Simplify @qapi-type test
PATCH 1/1 tests/qmp-cmd-test: Simplify @qapi-type test
test_qapi_type() checks that if @qapi-type is present, it resolves in output of query-qmp-schema. Absent @qapi-type is reported with g_test_message except for child and link properties.
The exception became useless when we implemented @qapi-type for child and link properties. Drop it.
Fixes 6955264d5821 ("qom: Convert child and link properties to QAPI-aware registration")
Signed-off-by Markus Armbruster <[email protected]>
--- tests/qtest/qmp-cmd-test.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-)
tests/qtest/qmp-cmd-test.c +1 -2
@@ -384,8 +384,7 @@ static void test_qapi_type(void)if (qapi_type) {g_assert_nonnull (qmp_schema_lookup (&schema, qapi_type)); - }else if (!g_str_has_prefix (ty,"child<" ) && - !g_str_has_prefix (ty,"link<" )) { + }else {g_test_message ("%s.%s %s has no associated qapi-type" , name, propname, ty); }
Signature · 1 line
2.55.0
Quoted 4 lines · Markus Armbruster
test_qapi_type()checks that if @qapi-type is present, it resolves in output of query-qmp-schema. Absent @qapi-type is reported withg_test_messageexcept for child and link properties.
Quoted 8 lines
The exception became useless when we implemented @qapi-type for child and link properties. Drop it.
Fixes 6955264d5821 ("qom: Convert child and link properties to QAPI-aware registration")Signed-off-by Markus Armbruster <[email protected]>--- tests/qtest/qmp-cmd-test.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-)
Reviewed-by Daniel P. Berrangé <[email protected]>
With regards,
Daniel
Signature · 3 lines
|: https://berrange.com ~~ https://hachyderm.io/@berrange :| |: https://libvirt.org ~~ https://entangle-photo.org :| |: https://pixelfed.art/berrange ~~ https://fstop138.berrange.com :|