summaryrefslogtreecommitdiff
path: root/tests
diff options
context:
space:
mode:
authorDodji Seketeli <dodji@gnome.org>2003-12-14 15:31:54 +0000
committerDodji Seketeli <dodji@src.gnome.org>2003-12-14 15:31:54 +0000
commit6460e61fb325bcc0f14f245450ae1a7c00096100 (patch)
tree26646c05963e551620450a9e8a10bd25631c486f /tests
parentfc3c35e2b52e4146d06d1d4c34989393bfc88b38 (diff)
downloadlibcroco-6460e61fb325bcc0f14f245450ae1a7c00096100.tar.gz
added a test case for the A + B type of selectors. added added these
2003-12-14 Dodji Seketeli <dodji@gnome.org> * docs/examples/selection-example-1.c: * docs/examples/selection-example-1.xml: * docs/examples/selection-example-1.css: added a test case for the A + B type of selectors. added * src/seleng/cr-sel-eng.c: (get_next_element_node) (get_prev_element_node) (get_next_parent_element_node): added these helper functions to help ignore non element nodes in the selector matcher. (sel_matches_node_real): Do not consider non element nodes when evaluating a selector.
Diffstat (limited to 'tests')
-rw-r--r--tests/test-inputs/test5.1.css1
-rw-r--r--tests/test5-main.c13
2 files changed, 7 insertions, 7 deletions
diff --git a/tests/test-inputs/test5.1.css b/tests/test-inputs/test5.1.css
index e6468fd..e5f2009 100644
--- a/tests/test-inputs/test5.1.css
+++ b/tests/test-inputs/test5.1.css
@@ -9,3 +9,4 @@ E0+E1{pro1:val1}
E1 E1-1 {prop2: val2}
E1 > E1-1 {prop3: val3}
document E1-1 {prop4: val4}
+
diff --git a/tests/test5-main.c b/tests/test5-main.c
index 1912027..6305543 100644
--- a/tests/test5-main.c
+++ b/tests/test5-main.c
@@ -38,7 +38,7 @@ CRDocHandler * gv_test_handler = {0} ;
const guchar *xml_content=
"<document>"
-"<E0>text0</E0>"
+"<E0>text0</E0> "
"<E1><E1-1>text1</E1-1></E1>"
"<E2 attr2=\"val2\">text2</E2>"
"<E3 attr3=\"val3_1 val3_2 val3_3\">text3</E3>"
@@ -133,14 +133,13 @@ walk_xml_tree_and_lookup_rules (CRSelEng *a_sel_eng,
g_print ("\n\nxml end element: %s\n",
cur_node->name);
g_print ("'''''''''''''''''''''''''\n") ;
-
- if (stmts_tab)
- {
- g_free (stmts_tab) ;
- stmts_tab= NULL ;
- }
}
+ if (stmts_tab)
+ {
+ g_free (stmts_tab) ;
+ stmts_tab= NULL ;
+ }
if (cur_node->children)
{
walk_xml_tree_and_lookup_rules