}
END_TEST
+/* Test the parsing of an empty string */
+START_TEST(test_empty_parse)
+{
+ if (XML_Parse(parser, NULL, 0, XML_FALSE) == XML_STATUS_ERROR)
+ fail("Parsing empty string faulted");
+ if (XML_Parse(parser, NULL, 0, XML_TRUE) != XML_STATUS_ERROR)
+ fail("Parsing final empty string not faulted");
+ if (XML_GetErrorCode(parser) != XML_ERROR_NO_ELEMENTS)
+ fail("Parsing final empty string faulted for wrong reason");
+}
+END_TEST
/*
* Namespaces tests.
tcase_add_test(tc_basic, test_explicit_encoding);
tcase_add_test(tc_basic, test_user_parameters);
tcase_add_test(tc_basic, test_ext_entity_ref_parameter);
+ tcase_add_test(tc_basic, test_empty_parse);
suite_add_tcase(s, tc_namespace);
tcase_add_checked_fixture(tc_namespace,