@pytest.mark.skipif((not PY3), reason='Only necessary on Python3')
def test_not_ascii():
 try:
  preferred_encoding = locale.getpreferredencoding()
  fs_enc = codecs.lookup(preferred_encoding).name
 except Exception:
  fs_enc = 'ascii'
 assert (fs_enc != 'ascii')

@ pytest . mark . skipif ( ( not PY3 ) , reason = 'Only necessary on Python3' ) def test_not_ascii ( ) : try : preferred_encoding = locale . getpreferredencoding ( ) fs_enc = codecs . lookup ( preferred_encoding ) . name except Exception : fs_enc = 'ascii' assert ( fs_enc != 'ascii' )
make sure that the systems preferred encoding is not ascii .