[Expat-checkins] CVS: expat/tests runtests.c,1.15,1.16

Fred L. Drake fdrake@users.sourceforge.net
Wed Apr 24 18:43:02 2002


Update of /cvsroot/expat/expat/tests
In directory usw-pr-cvs1:/tmp/cvs-serv16991/tests

Modified Files:
	runtests.c 
Log Message:
Make the organization slightly easier to discern.

Index: runtests.c
===================================================================
RCS file: /cvsroot/expat/expat/tests/runtests.c,v
retrieving revision 1.15
retrieving revision 1.16
diff -C2 -d -r1.15 -r1.16
*** runtests.c	24 Apr 2002 03:48:03 -0000	1.15
--- runtests.c	25 Apr 2002 01:42:34 -0000	1.16
***************
*** 45,48 ****
--- 45,53 ----
  #define xml_failure() _xml_failure(__FILE__, __LINE__)
  
+ 
+ /*
+  * Character & encoding tests.
+  */
+ 
  START_TEST(test_nul_byte)
  {
***************
*** 70,91 ****
  END_TEST
  
- 
- START_TEST(test_xmldecl_misplaced)
- {
-     char *text =
-         "\n"
-         "<?xml version='1.0'?>\n"
-         "<a>&eee;</a>";
- 
-     if (!XML_Parse(parser, text, strlen(text), 1)) {
-         if (XML_GetErrorCode(parser) != XML_ERROR_MISPLACED_XML_PI)
-             xml_failure();
-     }
-     else {
-         fail("expected XML_ERROR_MISPLACED_XML_PI with misplaced XML decl");
-     }
- }
- END_TEST
- 
  START_TEST(test_bom_utf8)
  {
--- 75,78 ----
***************
*** 312,315 ****
--- 299,306 ----
  
  
+ /*
+  * Attribute tests.
+  */
+ 
  /* Helpers used by the following test; this checks any "attr" and "refs"
   * attributes to make sure whitespace has been normalized.
***************
*** 417,420 ****
--- 408,433 ----
      if (!XML_Parse(parser, text, strlen(text), 1))
          xml_failure();
+ }
+ END_TEST
+ 
+ 
+ /*
+  * XML declaration tests.
+  */
+ 
+ START_TEST(test_xmldecl_misplaced)
+ {
+     char *text =
+         "\n"
+         "<?xml version='1.0'?>\n"
+         "<a>&eee;</a>";
+ 
+     if (!XML_Parse(parser, text, strlen(text), 1)) {
+         if (XML_GetErrorCode(parser) != XML_ERROR_MISPLACED_XML_PI)
+             xml_failure();
+     }
+     else {
+         fail("expected XML_ERROR_MISPLACED_XML_PI with misplaced XML decl");
+     }
  }
  END_TEST