Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 4 Nov 2014 16:02:47 +0000 (UTC)
From:      Garrett Cooper <ngie@FreeBSD.org>
To:        src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org
Subject:   svn commit: r274090 - head/contrib/netbsd-tests/lib/libc/locale
Message-ID:  <201411041602.sA4G2l3o059573@svn.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: ngie
Date: Tue Nov  4 16:02:46 2014
New Revision: 274090
URL: https://svnweb.freebsd.org/changeset/base/274090

Log:
  Fix the Jenkins test run by skipping the negative testcases earlier
  
  The problem is that lib.libc.locale.t_io:bad_big5_wprintf was printing out
  illegal Unicode characters, which causes XML parsers to bail immediately, e.g.
  
  % kyua report-junit > ~/report.junit
  % python2 -c 'import xml.dom.minidom as md; md.parse("/home/ngie/report.junit")'
  Traceback (most recent call last):
    File "<string>", line 1, in <module>
    File "/usr/local/lib/python2.7/xml/dom/minidom.py", line 1918, in parse
      return expatbuilder.parse(file)
    File "/usr/local/lib/python2.7/xml/dom/expatbuilder.py", line 924, in parse
      result = builder.parseFile(fp)
    File "/usr/local/lib/python2.7/xml/dom/expatbuilder.py", line 207, in parseFile
      parser.Parse(buffer, 0)
  xml.parsers.expat.ExpatError: not well-formed (invalid token): line 27137, column 13

Modified:
  head/contrib/netbsd-tests/lib/libc/locale/t_io.c

Modified: head/contrib/netbsd-tests/lib/libc/locale/t_io.c
==============================================================================
--- head/contrib/netbsd-tests/lib/libc/locale/t_io.c	Tue Nov  4 15:39:56 2014	(r274089)
+++ head/contrib/netbsd-tests/lib/libc/locale/t_io.c	Tue Nov  4 16:02:46 2014	(r274090)
@@ -53,14 +53,15 @@ ATF_TC_HEAD(bad_big5_wprintf, tc)
 
 ATF_TC_BODY(bad_big5_wprintf, tc)
 {
+#ifdef __FreeBSD__
+	atf_tc_skip("does not fail as expected (may be implementation "
+	    "specific issue with the test)");
+#endif
+
 	/* XXX implementation detail knowledge (wchar_t encoding) */
 	wchar_t ibuf[] = { 0xcf10, 0 };
 	setlocale(LC_CTYPE, "zh_TW.Big5");
 
-#if defined(__FreeBSD__)
-	atf_tc_expect_fail("does not fail as expected (may be implementation "
-	    "specific issue with the test)");
-#endif
 	ATF_REQUIRE_ERRNO(EILSEQ, wprintf(L"%ls\n", ibuf) < 0);
 	ATF_REQUIRE(ferror(stdout));
 }
@@ -73,15 +74,16 @@ ATF_TC_HEAD(bad_big5_swprintf, tc)
 
 ATF_TC_BODY(bad_big5_swprintf, tc)
 {
+#ifdef __FreeBSD__
+	atf_tc_skip("does not fail as expected (may be implementation "
+	    "specific issue with the test)");
+#endif
+
 	/* XXX implementation detail knowledge (wchar_t encoding) */
 	wchar_t ibuf[] = { 0xcf10, 0 };
 	wchar_t obuf[20];
 	setlocale(LC_CTYPE, "zh_TW.Big5");
 
-#if defined(__FreeBSD__)
-	atf_tc_expect_fail("does not fail as expected (may be implementation "
-	    "specific issue with the test)");
-#endif
 	ATF_REQUIRE_ERRNO(EILSEQ,
 			  swprintf(obuf, sizeof(obuf), L"%ls\n", ibuf) < 0);
 }
@@ -171,7 +173,7 @@ ATF_TC_BODY(bad_big5_getwc, tc)
 
 	ATF_REQUIRE(fp != NULL);
 	setlocale(LC_CTYPE, "zh_TW.Big5");
-#if defined(__FreeBSD__)
+#ifdef __FreeBSD__
 	atf_tc_expect_fail("does not return WEOF as expected");
 #endif
 	ATF_REQUIRE_EQ(getwc(fp), WEOF);



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201411041602.sA4G2l3o059573>