@test_support.requires_unicode
    def test_expandvars_nonascii_word(self):
        encoding = sys.getfilesystemencoding()
        # Non-ASCII word characters
        letters = test_support.u(r'\xe6\u0130\u0141\u03c6\u041a\u05d0\u062a\u0e01')
        uwnonascii = letters.encode(encoding, 'ignore').decode(encoding)[:3]
        swnonascii = uwnonascii.encode(encoding)
        if not swnonascii:
            self.skipTest('Needs non-ASCII word characters')
        with test_support.EnvironmentVarGuard() as env:
            env.clear()
            env[swnonascii] = 'baz' + swnonascii
            self.assertEqual(posixpath.expandvars(u'$%s bar' % uwnonascii),
                             u'baz%s bar' % uwnonascii)
dataset/ETHPy150Open francelabs/datafari/windows/python/Lib/test/test_posixpath.py/PosixPathTest.test_expandvars_nonascii_word/original