From b8b108f306bebf90d386f6c9d14c552f62a73746 Mon Sep 17 00:00:00 2001 From: Collin Winter Date: Fri, 20 Jul 2007 18:08:03 +0000 Subject: [PATCH] Make doctest pass by specifying the right encoding. --- Lib/doctest.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Lib/doctest.py b/Lib/doctest.py index bd7a9183464..3f139fc5553 100644 --- a/Lib/doctest.py +++ b/Lib/doctest.py @@ -210,7 +210,7 @@ def _load_testfile(filename, package, module_relative): if hasattr(package, '__loader__'): if hasattr(package.__loader__, 'get_data'): return package.__loader__.get_data(filename), filename - return open(filename).read(), filename + return open(filename, encoding="utf-8").read(), filename def _indent(s, indent=4): """