diff options
author | Richard Hughes <richard@hughsie.com> | 2017-06-27 15:42:22 +0100 |
---|---|---|
committer | Richard Hughes <richard@hughsie.com> | 2017-06-27 15:42:22 +0100 |
commit | 5aacd135b45a3256200c4381ffff88a13c118ff1 (patch) | |
tree | 2c3b00dc7e0f18eac7e096ce3db795a01ae1671f /libappstream-glib/as-self-test.c | |
parent | e11abd151fd6c7931f96b42a43f9f2a979a51da5 (diff) | |
download | appstream-glib-5aacd135b45a3256200c4381ffff88a13c118ff1.tar.gz |
Validate the <id> format according to the spec
Diffstat (limited to 'libappstream-glib/as-self-test.c')
-rw-r--r-- | libappstream-glib/as-self-test.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/libappstream-glib/as-self-test.c b/libappstream-glib/as-self-test.c index 3df66f6..b3f043b 100644 --- a/libappstream-glib/as-self-test.c +++ b/libappstream-glib/as-self-test.c @@ -2190,13 +2190,15 @@ as_test_app_validate_file_bad_func (void) "<release> timestamp is in the future"); as_test_app_validate_check (probs, AS_PROBLEM_KIND_TAG_MISSING, "<content_rating> required for game"); - g_assert_cmpint (probs->len, ==, 35); + as_test_app_validate_check (probs, AS_PROBLEM_KIND_MARKUP_INVALID, + "<id> has invalid character"); + g_assert_cmpint (probs->len, ==, 36); /* again, harder */ probs2 = as_app_validate (app, AS_APP_VALIDATE_FLAG_STRICT, &error); as_test_app_validate_check (probs2, AS_PROBLEM_KIND_TAG_INVALID, "XML data contains unknown tag"); - g_assert_cmpint (probs2->len, ==, 41); + g_assert_cmpint (probs2->len, ==, 42); } static void |