* nstrftime tests: Avoid test failures on FreeBSD, NetBSD, Android
@ 2024-02-07 11:53 Bruno Haible
2024-02-07 15:54 ` Bruno Haible
0 siblings, 1 reply; 2+ messages in thread
From: Bruno Haible @ 2024-02-07 11:53 UTC (permalink / raw)
To: bug-gnulib
On FreeBSD 5.2.1, NetBSD 7.1.1, and Android 11, I'm seeing test failures of
the 'test-nstrftime' test. I once started to debug this [1][2], but ran out of
time.
[1] https://lists.gnu.org/archive/html/bug-gnulib/2023-01/msg00153.html
[2] https://lists.gnu.org/archive/html/bug-gnulib/2023-04/msg00170.html
On FreeBSD 11, there is no failure any more. This indicates that the cause
may simply be old timezone data packaged in the operating system.
So, avoid the test failures that are too costly to fix.
2024-02-07 Bruno Haible <bruno@clisp.org>
nstrftime tests: Avoid test failures on FreeBSD, NetBSD, Android.
* tests/test-nstrftime.h (LT): Disable specific test cases on FreeBSD,
NetBSD, Android.
diff --git a/tests/test-nstrftime.h b/tests/test-nstrftime.h
index 7480ddf6d7..294a1aaf2c 100644
--- a/tests/test-nstrftime.h
+++ b/tests/test-nstrftime.h
@@ -116,12 +116,18 @@ struct localtime_rz_test
static struct localtime_rz_test LT[] =
{
+#if !(defined __NetBSD__ || defined __ANDROID__)
{ TZ+Pacific, 0, "1969-12-31 16:00:00 -0800 (PST)", 0 },
+#endif
{ TZ+Arizona, 0, "1969-12-31 17:00:00 -0700 (MST)", 0 },
{ TZ+UTC , 0, "1970-01-01 00:00:00 +0000 (UTC)", 0 },
+#if !(defined __NetBSD__ || defined __ANDROID__)
{ TZ+CentEur, 0, "1970-01-01 01:00:00 +0100 (CET)", 0 },
+#endif
{ TZ+Japan , 0, "1970-01-01 09:00:00 +0900 (JST)", 0 },
+#if !defined __FreeBSD__
{ TZ+NZ , 0, "1970-01-01 13:00:00 +1300 (NZDT)", 1 },
+#endif
{ TZ+Pacific, 500000001, "1985-11-04 16:53:21 -0800 (PST)", 0 },
{ TZ+Arizona, 500000001, "1985-11-04 17:53:21 -0700 (MST)", 0 },
{ TZ+UTC , 500000001, "1985-11-05 00:53:21 +0000 (UTC)", 0 },
@@ -134,7 +140,7 @@ static struct localtime_rz_test LT[] =
{ TZ+CentEur, 1000000002, "2001-09-09 03:46:42 +0200 (CEST)", 0 },
{ TZ+Japan , 1000000002, "2001-09-09 10:46:42 +0900 (JST)", 0 },
{ TZ+NZ , 1000000002, "2001-09-09 13:46:42 +1200 (NZST)", 0 },
-#if TZ_ANGLE_BRACKETS_SHOULD_WORK
+#if TZ_ANGLE_BRACKETS_SHOULD_WORK && !defined __FreeBSD__
{ TZ+Unknown, 0, "1970-01-01 00:00:00 -0000 (-00)", 0 },
{ TZ+Unknown, 500000001, "1985-11-05 00:53:21 -0000 (-00)", 0 },
{ TZ+Unknown, 1000000002, "2001-09-09 01:46:42 -0000 (-00)", 0 },
^ permalink raw reply related [flat|nested] 2+ messages in thread
* Re: nstrftime tests: Avoid test failures on FreeBSD, NetBSD, Android
2024-02-07 11:53 nstrftime tests: Avoid test failures on FreeBSD, NetBSD, Android Bruno Haible
@ 2024-02-07 15:54 ` Bruno Haible
0 siblings, 0 replies; 2+ messages in thread
From: Bruno Haible @ 2024-02-07 15:54 UTC (permalink / raw)
To: bug-gnulib
Likewise on DragonFly BSD 6.0.
2024-02-07 Bruno Haible <bruno@clisp.org>
nstrftime tests: Avoid test failures on DragonFly BSD.
* tests/test-nstrftime.h (LT): Disable specific test cases also on
DragonFly BSD.
diff --git a/tests/test-nstrftime.h b/tests/test-nstrftime.h
index 294a1aaf2c..97190a6654 100644
--- a/tests/test-nstrftime.h
+++ b/tests/test-nstrftime.h
@@ -116,12 +116,12 @@ struct localtime_rz_test
static struct localtime_rz_test LT[] =
{
-#if !(defined __NetBSD__ || defined __ANDROID__)
+#if !(defined __DragonFly__ || defined __NetBSD__ || defined __ANDROID__)
{ TZ+Pacific, 0, "1969-12-31 16:00:00 -0800 (PST)", 0 },
#endif
{ TZ+Arizona, 0, "1969-12-31 17:00:00 -0700 (MST)", 0 },
{ TZ+UTC , 0, "1970-01-01 00:00:00 +0000 (UTC)", 0 },
-#if !(defined __NetBSD__ || defined __ANDROID__)
+#if !(defined __DragonFly__ || defined __NetBSD__ || defined __ANDROID__)
{ TZ+CentEur, 0, "1970-01-01 01:00:00 +0100 (CET)", 0 },
#endif
{ TZ+Japan , 0, "1970-01-01 09:00:00 +0900 (JST)", 0 },
^ permalink raw reply related [flat|nested] 2+ messages in thread
end of thread, other threads:[~2024-02-07 15:54 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-02-07 11:53 nstrftime tests: Avoid test failures on FreeBSD, NetBSD, Android Bruno Haible
2024-02-07 15:54 ` Bruno Haible
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).