From 642f1bd0ec000df0a0b110b03cfc806f2e5d9fd4 Mon Sep 17 00:00:00 2001 From: David Baumgold Date: Fri, 7 Mar 2014 13:01:52 -0500 Subject: [PATCH] Fix unicode issues with tests --- willie/modules/units.py | 1 + willie/test_tools.py | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/willie/modules/units.py b/willie/modules/units.py index a7ce445b1c..51a4d89d25 100644 --- a/willie/modules/units.py +++ b/willie/modules/units.py @@ -6,6 +6,7 @@ Licensed under the Eiffel Forum License 2. """ +from __future__ import unicode_literals from willie.module import commands, example, NOLIMIT import re diff --git a/willie/test_tools.py b/willie/test_tools.py index b3fa9530ba..1c00f8cb39 100644 --- a/willie/test_tools.py +++ b/willie/test_tools.py @@ -110,7 +110,7 @@ def test(): assert len(wrapper.output) == len(results) for result, output in zip(results, wrapper.output): if type(output) is bytes: - output = output.decode() + output = output.decode('utf-8') if use_regexp: if not re.match(result, output): assert result == output