[glib] tests: add a ignore-qualified markup-collect case
- From: Ryan Lortie <desrt src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [glib] tests: add a ignore-qualified markup-collect case
- Date: Mon, 28 Oct 2013 22:25:20 +0000 (UTC)
commit 1bc98830c5a3ffe5a43e5e05730064cb149f25bd
Author: Ryan Lortie <desrt desrt ca>
Date: Mon Oct 28 14:11:05 2013 -0700
tests: add a ignore-qualified markup-collect case
Add a case to markup-collect that exercises the new IGNORE_QUALIFIED
flag.
https://bugzilla.gnome.org/show_bug.cgi?id=665634
glib/tests/markup-collect.c | 5 ++++-
1 files changed, 4 insertions(+), 1 deletions(-)
---
diff --git a/glib/tests/markup-collect.c b/glib/tests/markup-collect.c
index 46d2a42..b9890b7 100644
--- a/glib/tests/markup-collect.c
+++ b/glib/tests/markup-collect.c
@@ -96,6 +96,9 @@ static struct test tests[] =
{ "<bool mb='t' ob='f' tri='1'/>", "<bool(1) 1 0 1>" },
{ "<bool mb='y' ob='n' tri='0'/>", "<bool(1) 1 0 0>" },
+ { "<bool mb='y' my:attr='q'><my:tag/></bool>", "<bool(1) 1 0 -1>" },
+ { "<bool mb='y' my:attr='q'><my:tag>some <b>text</b> is in here</my:tag></bool>", "<bool(1) 1 0 -1>" },
+
{ "<bool ob='y'/>", "<bool(0) 0 0 -1>",
G_MARKUP_ERROR_MISSING_ATTRIBUTE, "'mb'" },
@@ -147,7 +150,7 @@ test_collect (gconstpointer d)
gboolean result;
string = g_string_new ("");
- ctx = g_markup_parse_context_new (&parser, 0, string, NULL);
+ ctx = g_markup_parse_context_new (&parser, G_MARKUP_IGNORE_QUALIFIED, string, NULL);
result = g_markup_parse_context_parse (ctx,
test->document,
-1, &error);
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]