From 1971888c9daa73514492252cac38112b6ccfe325 Mon Sep 17 00:00:00 2001 From: THIEBAUT Fabrice Date: Fri, 16 Aug 2024 15:49:36 +0200 Subject: [PATCH] Update tests.py MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit problème de décodage à cause de "é" de étudiant dans main.py --- "P1/P1C5/\303\251nonc\303\251/tests.py" | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git "a/P1/P1C5/\303\251nonc\303\251/tests.py" "b/P1/P1C5/\303\251nonc\303\251/tests.py" index e483ec33..a9bd758d 100644 --- "a/P1/P1C5/\303\251nonc\303\251/tests.py" +++ "b/P1/P1C5/\303\251nonc\303\251/tests.py" @@ -5,7 +5,7 @@ def run_main_file(): python_cmd = "python" if sys.version_info.major == 2 else "python3" - process = subprocess.Popen([python_cmd, "main.py"], stdout=subprocess.PIPE) + process = subprocess.Popen([python_cmd, "-X", "utf8", "main.py"], stdout=subprocess.PIPE) # problème de décodage à cause de "é" de étudiant dans main.py output, error = process.communicate() return output.decode()