devtools/test/unittest_dbfill.py
changeset 10773 5b051dd4a4f5
parent 10614 57dfde80df11
--- a/devtools/test/unittest_dbfill.py	Mon Oct 05 16:54:12 2015 +0200
+++ b/devtools/test/unittest_dbfill.py	Mon Oct 05 16:59:18 2015 +0200
@@ -21,6 +21,7 @@
 import os.path as osp
 import re
 import datetime
+import io
 
 from six.moves import range
 
@@ -52,7 +53,7 @@
             return None
 
     def _available_Person_firstname(self, etype, attrname):
-        return [f.strip() for f in open(osp.join(DATADIR, 'firstnames.txt'))]
+        return [f.strip() for f in io.open(osp.join(DATADIR, 'firstnames.txt'), encoding='latin1')]
 
     def setUp(self):
         config = ApptestConfiguration('data', apphome=DATADIR)