From bf322d0e94abf67fc407abb26c9718c3ac73d2d4 Mon Sep 17 00:00:00 2001 From: Hemanth U <77799372+hemanth-thirthahalli@users.noreply.github.com> Date: Tue, 2 Dec 2025 09:32:38 +0530 Subject: [PATCH] =?utf8?q?=F0=9F=90=9B=20Fix=20Windows=20UnicodeEncodeErro?= =?utf8?q?r=20in=20CLI=20test=20(#14295)?= MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit Co-authored-by: Sofie Van Landeghem Co-authored-by: Sebastián Ramírez --- tests/test_fastapi_cli.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/tests/test_fastapi_cli.py b/tests/test_fastapi_cli.py index a5c10778ad..78a49a1fbe 100644 --- a/tests/test_fastapi_cli.py +++ b/tests/test_fastapi_cli.py @@ -1,3 +1,4 @@ +import os import subprocess import sys from unittest.mock import patch @@ -20,6 +21,7 @@ def test_fastapi_cli(): ], capture_output=True, encoding="utf-8", + env={**os.environ, "PYTHONIOENCODING": "utf-8"}, ) assert result.returncode == 1, result.stdout assert "Path does not exist non_existent_file.py" in result.stdout -- 2.47.3