I've encountered what appears to be a Heisenbug in runtest.

Sometimes, when I run "make check", I see

--------8<--------
[ -d test   ] || ln -s /afs/teragram.com/user/dgomez/prog/libxml2/test   .
[ -d result ] || ln -s /afs/teragram.com/user/dgomez/prog/libxml2/result .
./runtest &&  ./testrecurse && ./testapi &&  ./testchar&&  ./testdict &&  
./runxmlconf
## XML regression tests
## XML regression tests on memory
## XML entity subst regression tests
## XML Namespaces regression tests
## Error cases regression tests
Error for ./test/errors/name2.xml failed
File ./test/errors/name2.xml generated an error
## Error cases stream regression tests
## Reader regression tests
## Reader entities substitution regression tests
[snip]
## C14N exclusive without comments regression tests
## C14N 1.1 without comments regression tests
## Catalog and Threads regression tests
Total 2829 tests, 1 errors, 0 leaks
make: *** [runtests] Error 1
-------->8--------

Other times, everything passes. If I invoke runtest by itself, it doesn't even fail or succeed consistently. Valgrind turns up nothing.

I believe I've found a way for others to reproduce the issue. The attached patch (against git master) disables all but the "Error cases regression tests" set of tests, and with this change, I get a consistent test failure:

--------8<--------
$ ./runtest
## Error cases regression tests
Error for ./test/errors/name2.xml failed
File ./test/errors/name2.xml generated an error
Total 11 tests, 1 errors, 0 leaks
-------->8--------

I've been unable to track down what's going on, as it occurs deep inside the parser code and I'm not on strong footing there.

Can anyone else reproduce this, using the patch?


--Daniel


--
Daniel Richard G. || dani...@teragram.com || Software Developer
Teragram Linguistic Technologies (a division of SAS)
http://www.teragram.com/
diff --git a/runtest.c b/runtest.c
index c7214f2..ea8a852 100644
--- a/runtest.c
+++ b/runtest.c
@@ -4143,6 +4143,7 @@ threadsTest(const char *filename ATTRIBUTE_UNUSED,
 
 static
 testDesc testDescriptions[] = {
+#if 0
     { "XML regression tests" ,
       oldParseTest, "./test/*", "result/", "", NULL,
       0 },
@@ -4155,9 +4156,11 @@ testDesc testDescriptions[] = {
     { "XML Namespaces regression tests",
       errParseTest, "./test/namespaces/*", "result/namespaces/", "", ".err",
       0 },
+#endif /* 0 */
     { "Error cases regression tests",
       errParseTest, "./test/errors/*.xml", "result/errors/", "", ".err",
       0 },
+#if 0
 #ifdef LIBXML_READER_ENABLED
     { "Error cases stream regression tests",
       streamParseTest, "./test/errors/*.xml", "result/errors/", NULL, ".str",
@@ -4302,6 +4305,7 @@ testDesc testDescriptions[] = {
       threadsTest, NULL, NULL, NULL, NULL,
       0 },
 #endif
+#endif /* 0 */
     {NULL, NULL, NULL, NULL, NULL, NULL, 0}
 };
 
_______________________________________________
xml mailing list, project page  http://xmlsoft.org/
xml@gnome.org
https://mail.gnome.org/mailman/listinfo/xml

Reply via email to