Bzyczek wrote: > So my question is: Is it possible to run doctests with UTF-8 > characters? And if your answer will be YES, tell me please how...
Use raw strings in combination with explicit decoding and a little try-and-error. E. g. this little gem passes ;) # -*- coding: utf8 -*- r""" >>> f("äöü".decode("utf8")) (u'\xe4\xf6\xfc',) """ def f(s): return (s,) if __name__ == "__main__": import doctest doctest.testmod() Peter -- http://mail.python.org/mailman/listinfo/python-list