def test_unicode_doctest_module(self, testdir):
    '\n        Test case for issue 2434: DecodeError on Python 2 when doctest docstring\n        contains non-ascii characters.\n        '
    p = testdir.makepyfile(test_unicode_doctest_module='\n            def fix_bad_unicode(text):\n                \'\'\'\n                    >>> print(fix_bad_unicode(\'Ãºnico\'))\n                    único\n                \'\'\'\n                return "único"\n        ')
    result = testdir.runpytest(p, '--doctest-modules')
    result.stdout.fnmatch_lines(['* 1 passed *'])
Test case for issue 2434: DecodeError on Python 2 when doctest docstring
contains non-ascii characters.
def test_unicode_doctest_module(self, testdir):
    '\n        Test case for issue 2434: DecodeError on Python 2 when doctest docstring\n        contains non-ascii characters.\n        '
    p = testdir.makepyfile(test_unicode_doctest_module='\n            def fix_bad_unicode(text):\n                \'\'\'\n                    >>> print(fix_bad_unicode(\'Ãºnico\'))\n                    único\n                \'\'\'\n                return "único"\n        ')
    result = testdir.runpytest(p, '--doctest-modules')
    result.stdout.fnmatch_lines(['* 1 passed *'])