diff options
Diffstat (limited to 'testing/libc++/disable-broken-tests.patch')
-rw-r--r-- | testing/libc++/disable-broken-tests.patch | 68 |
1 files changed, 68 insertions, 0 deletions
diff --git a/testing/libc++/disable-broken-tests.patch b/testing/libc++/disable-broken-tests.patch new file mode 100644 index 0000000000..84798765da --- /dev/null +++ b/testing/libc++/disable-broken-tests.patch @@ -0,0 +1,68 @@ +musl doesn't support the locale things that the locale requirements test, like +localized money and decimal formatting. + +The syscat.errcat tests are broken and rely on the libc to return a specific +string in the form of "Unknown error <n>" for unknown errnos when calling +strerror(), which is not defined anywhere and libcs are free to return any +string they want, up to and including "libcxx tests are silly". + +Similarly to glibc, musl uses "NaN" to format NaN long doubles, not "nan". +Finally, musl uses "0" to indicate a NULL pointer as %p argument to *printf(). + +diff -Nru a/libcxx/test/std/diagnostics/syserr/syserr.errcat/syserr.errcat.objects/generic_category.pass.cpp b/libcxx/test/std/diagnostics/syserr/syserr.errcat/syserr.errcat.objects/generic_category.pass.cpp +--- a/libcxx/test/std/diagnostics/syserr/syserr.errcat/syserr.errcat.objects/generic_category.pass.cpp 2016-06-14 06:37:36.000000000 +0000 ++++ b/libcxx/test/std/diagnostics/syserr/syserr.errcat/syserr.errcat.objects/generic_category.pass.cpp 2017-05-15 01:08:24.868284337 +0000 +@@ -7,6 +7,8 @@ + // + //===----------------------------------------------------------------------===// + ++// XFAIL: libcpp-has-musl-libc ++ + // <system_error> + + // class error_category +diff -Nru a/libcxx/test/std/diagnostics/syserr/syserr.errcat/syserr.errcat.objects/system_category.pass.cpp b/libcxx/test/std/diagnostics/syserr/syserr.errcat/syserr.errcat.objects/system_category.pass.cpp +--- a/libcxx/test/std/diagnostics/syserr/syserr.errcat/syserr.errcat.objects/system_category.pass.cpp 2016-06-14 06:37:36.000000000 +0000 ++++ b/libcxx/test/std/diagnostics/syserr/syserr.errcat/syserr.errcat.objects/system_category.pass.cpp 2017-05-15 01:08:09.171161729 +0000 +@@ -7,6 +7,8 @@ + // + //===----------------------------------------------------------------------===// + ++// XFAIL: libcpp-has-musl-libc ++ + // <system_error> + + // class error_category +diff -Nru a/libcxx/test/std/localization/locale.categories/category.numeric/locale.nm.put/facet.num.put.members/put_long_double.pass.cpp b/libcxx/test/std/localization/locale.categories/category.numeric/locale.nm.put/facet.num.put.members/put_long_double.pass.cpp +--- a/libcxx/test/std/localization/locale.categories/category.numeric/locale.nm.put/facet.num.put.members/put_long_double.pass.cpp 2016-12-24 01:07:54.000000000 +0000 ++++ b/libcxx/test/std/localization/locale.categories/category.numeric/locale.nm.put/facet.num.put.members/put_long_double.pass.cpp 2017-05-15 02:02:23.221864590 +0000 +@@ -18,6 +18,7 @@ + + // TODO GLIBC uses a different string for positive and negative NAN numbers. + // XFAIL: linux-gnu ++// XFAIL: libcpp-has-musl-libc + + #include <locale> + #include <ios> +diff -Nru a/libcxx/test/std/localization/locale.categories/category.numeric/locale.nm.put/facet.num.put.members/put_pointer.pass.cpp b/libcxx/test/std/localization/locale.categories/category.numeric/locale.nm.put/facet.num.put.members/put_pointer.pass.cpp +--- a/libcxx/test/std/localization/locale.categories/category.numeric/locale.nm.put/facet.num.put.members/put_pointer.pass.cpp 2017-05-15 02:01:56.842668781 +0000 ++++ b/libcxx/test/std/localization/locale.categories/category.numeric/locale.nm.put/facet.num.put.members/put_pointer.pass.cpp 2017-05-15 02:11:41.668288608 +0000 +@@ -38,6 +38,6 @@ + char str[50]; + output_iterator<char*> iter = f.put(output_iterator<char*>(str), ios, '*', v); + std::string ex(str, iter.base()); +- assert(ex == "0x0" || ex == "(nil)"); ++ assert(ex == "0" || ex == "0x0" || ex == "(nil)"); + } + } +diff -Nru a/libcxx/test/libcxx/test/target_info.py b/libcxx/test/libcxx/test/target_info.py +--- a/libcxx/test/libcxx/test/target_info.py 2017-05-15 23:31:06.698175150 +0000 ++++ b/libcxx/test/libcxx/test/target_info.py 2017-05-15 23:34:59.805751050 +0000 +@@ -35,6 +35,7 @@ + + def test_locale(loc): + assert loc is not None ++ return False + default_locale = locale.setlocale(locale.LC_ALL) + try: + locale.setlocale(locale.LC_ALL, loc) |