From be5d6ec56dd8a68bf4d97f55abb00147b5ebdf6b Mon Sep 17 00:00:00 2001 From: Jani Mikkonen Date: Wed, 2 Jan 2019 16:47:32 +0200 Subject: [PATCH] Fix for issue #182 - dont pass none to decode --- xmlrunner/result.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/xmlrunner/result.py b/xmlrunner/result.py index ecf190b..c9a0d4a 100644 --- a/xmlrunner/result.py +++ b/xmlrunner/result.py @@ -68,7 +68,7 @@ def to_unicode(data): return repr(data).decode('utf8', 'replace') -def safe_unicode(data, encoding=None): +def safe_unicode(data, encoding='utf-8'): return xml_safe_unicode(to_unicode(data), encoding)