1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21
|
From: Michael Fladischer <FladischerMichael@fladi.at>
Date: Sat, 22 Dec 2018 20:22:10 +0100
Subject: Open tests.ldif as UTF-8 for Python 2 compatibility.
---
tests/tests.py | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/tests/tests.py b/tests/tests.py
index fe1066d..a8fcaf8 100644
--- a/tests/tests.py
+++ b/tests/tests.py
@@ -134,7 +134,7 @@ class LDAPTest(TestCase):
'nis.schema',
]
cls.server.start()
- with io.open(os.path.join(here, 'tests.ldif')) as fp:
+ with io.open(os.path.join(here, 'tests.ldif'), encoding='utf-8') as fp:
ldif = fp.read()
cls.server.ldapadd(ldif)
|