FAIL: test-iconv.sh
tyanas opened this issue · comments
Making check in test
/Applications/Xcode.app/Contents/Developer/usr/bin/make check-TESTS
$ cat test/test-iconv.sh.log
1,3c1,4
< n�por po�ouchl�ch �lut�ch ���an� p�ehlu�il i zu��c� ork�n
< n�por po�ouchl�ch �lut�ch ���an� p�ehlu�il i zu��c� ork�n
< n�por po�ouchl�ch �lut�ch ���an� p�ehlu�il i zu��c� ork�n
---
> nápor poťouchlých žlutých číňanů přehlušil i zuřící orkán
> nápor poťouchlých žlutých číňanů přehlušil i zuřící orkán
> nápor poťouchlých žlutých číňanů přehlušil i zuřící orkán
> �
What locales do you have set to run the tests?
So it seems to be cs-s.utf8……That's what Google said……
I'm seeing this same issue.
Can you reproduce this with latest release as well? There have been some minor corrections in testsuite...
test-iconv.sh still fails for me on OS X (with enca 1.16). This is the output from locale
:
$ locale
LANG="en_US.UTF-8"
LC_COLLATE="en_US.UTF-8"
LC_CTYPE="en_US.UTF-8"
LC_MESSAGES="en_US.UTF-8"
LC_MONETARY="en_US.UTF-8"
LC_NUMERIC="en_US.UTF-8"
LC_TIME="en_US.UTF-8"
LC_ALL=
on OS X, i meet the same problem.
when i add a '\n' at the end of file test-iconv.actual, the problem disappears.
i debug it, find iconv return E_INVAL on OS X , but return EILSEQ on linux.
so, i modify src/convert_iconv.c +143 from 'if (errno == EINVAL) {' to 'if (errno == EINVAL && !hit_eof ) {',
the test case is ok.
@nijel , Maybe has other good way
I confirm that @pkujhd patch to src/convert_iconv.c works for me as well on 10.11.2
Indeed the fix looks correct, I've just committed it.
Version 1.17 is out with this fix, see https://blog.cihar.com/archives/2016/01/04/enca-117/. Another good news for OSX is that the testsuite is executed on Travis CI for OSX as well, so this kind of errors will be caught earlier...