Martin Storsjö wrote: > FAIL: test-strsignal The cause is that strsignal (SIGHUP) here is "Hangup 1", not just "Hangup".
This patch fixes the test. 2020-12-02 Bruno Haible <br...@clisp.org> strsignal-tests: Fix test failure on macOS 10.13. Reported by Martin Storsjö <mar...@martin.st> in <https://lists.gnu.org/archive/html/bug-gnulib/2020-12/msg00003.html>. * tests/test-strsignal.c (ASSERT_DESCRIPTION): Allow the actual result to be longer than the expected result. diff --git a/tests/test-strsignal.c b/tests/test-strsignal.c index 0316d40..1f8aeba 100644 --- a/tests/test-strsignal.c +++ b/tests/test-strsignal.c @@ -28,10 +28,12 @@ SIGNATURE_CHECK (strsignal, char *, (int)); #include "macros.h" #if HAVE_DECL_SYS_SIGLIST -# define ASSERT_DESCRIPTION(got, expect) +# define ASSERT_DESCRIPTION(actual, expected) #else -/* In this case, we can guarantee some signal descriptions. */ -# define ASSERT_DESCRIPTION(got, expect) ASSERT (!strcmp (got, expect)) +/* In this case, we can guarantee some signal descriptions. + But allow the actual result to be longer than the expected result. */ +# define ASSERT_DESCRIPTION(actual, expected) \ + ASSERT (strncmp (actual, expected, strlen (expected)) == 0) #endif int