[issue35290] [FreeBSD] test_c_locale_coercion doesn't support new C.UTF-8 locale of FreeBSD CURRENT

STINNER Victor report at bugs.python.org
Thu Nov 22 09:01:57 EST 2018


STINNER Victor <vstinner at redhat.com> added the comment:

> I'm wondering if we may need to make test_c_locale_coercion less opinionated, where for most platforms it's just a "don't segfault" test, and it's only for ones where we're certain about how we expect it to behave (i.e. Linux, Mac OS X, AIX, maybe FreeBSD) that we try to check the specifics.

For test_embed, I tried to be smart to guess the encodings (ex: hardcode some encodings depending on  the platform) and... I gave up. It's very hard when you consider Linux, Windows, macOS, FreeBSD, but also HP-UX and AIX. Each platform has weird cases about encodings... Now the test spawns a Python subprocess to get the encoding. See get_stdio_encoding() and get_filesystem_encoding() in Lib/test/test_embed.py.

----------

_______________________________________
Python tracker <report at bugs.python.org>
<https://bugs.python.org/issue35290>
_______________________________________


More information about the Python-bugs-list mailing list