t4210: skip i18n tests that don't work on FreeBSD
commit7187c7bbb8184ec52726acdbe0eb2ddc98a4fb7e
authorEd Maste <emaste@freebsd.org>
Wed, 27 Nov 2019 17:15:07 +0000 (27 17:15 +0000)
committerJunio C Hamano <gitster@pobox.com>
Sat, 30 Nov 2019 21:51:49 +0000 (30 13:51 -0800)
tree5dd93b6b270657f99bd074daf51583ad1c89b031
parentd9f6f3b6195a0ca35642561e530798ad1469bd41
t4210: skip i18n tests that don't work on FreeBSD

A number of t4210-log-i18n tests added in 4e2443b181 set LC_ALL to a UTF-8
locale (is_IS.UTF-8) but then pass an invalid UTF-8 string to --grep.
FreeBSD's regcomp() fails in this case with REG_ILLSEQ, "illegal byte
sequence," which git then passes to die():

fatal: command line: '�': illegal byte sequence

When these tests were added the commit message stated:

| It's possible that this
| test breaks the "basic" and "extended" backends on some systems that
| are more anal than glibc about the encoding of locale issues with
| POSIX functions that I can remember

which seems to be the case here.

Extend test-lib.sh to add a REGEX_ILLSEQ prereq, set it on FreeBSD, and
add !REGEX_ILLSEQ to the two affected tests.

Signed-off-by: Ed Maste <emaste@freebsd.org>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
t/t4210-log-i18n.sh
t/test-lib.sh