From 2841fe8c08728261edbf81ea36306b0f2e313f3e Mon Sep 17 00:00:00 2001 From: Orion Poplawski Date: Wed, 6 Apr 2016 22:26:22 -0600 Subject: [PATCH] Encode unicode string as utf8 in test. Fixes #38 --- tests/process_test_set.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tests/process_test_set.py b/tests/process_test_set.py index 9cbb5b1..4683ce8 100644 --- a/tests/process_test_set.py +++ b/tests/process_test_set.py @@ -105,7 +105,7 @@ def exception_message_contains_output_as_string_if_encoding_is_set(shell): @test def exception_message_shows_unicode_bytes(shell): try: - shell.run(["sh", "-c", _u("echo ‽; exit 1")]) + shell.run(["sh", "-c", _u("echo ‽; exit 1").encode("utf8")]) assert_true(False) except spur.RunProcessError as error: assert_equal(