From b1af11a87a45b55ed2422aaef9b8211f0bdd15ce Mon Sep 17 00:00:00 2001 From: Asti1982 <65121113+Asti1982@users.noreply.github.com> Date: Tue, 12 May 2026 23:04:49 +0200 Subject: [PATCH] fix: read wRTC dashboard fixtures as UTF-8 --- tools/wrtc-bridge-dashboard/test_bridge_dashboard.py | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/tools/wrtc-bridge-dashboard/test_bridge_dashboard.py b/tools/wrtc-bridge-dashboard/test_bridge_dashboard.py index 1ba4748b2..5e57fd30f 100644 --- a/tools/wrtc-bridge-dashboard/test_bridge_dashboard.py +++ b/tools/wrtc-bridge-dashboard/test_bridge_dashboard.py @@ -1,4 +1,5 @@ #!/usr/bin/env python3 +# SPDX-License-Identifier: MIT """ Tests for wRTC Bridge Dashboard Run: python -m pytest tools/wrtc-bridge-dashboard/test_bridge_dashboard.py -v @@ -14,7 +15,7 @@ class TestHTMLStructure(unittest.TestCase): @classmethod def setUpClass(cls): - with open(os.path.join(HERE, "index.html")) as f: + with open(os.path.join(HERE, "index.html"), encoding="utf-8") as f: cls.html = f.read() def test_has_title(self): @@ -54,7 +55,7 @@ def test_no_external_deps(self): class TestJSStructure(unittest.TestCase): @classmethod def setUpClass(cls): - with open(os.path.join(HERE, "bridge_dashboard.js")) as f: + with open(os.path.join(HERE, "bridge_dashboard.js"), encoding="utf-8") as f: cls.js = f.read() def test_rustchain_api(self): @@ -121,7 +122,7 @@ def test_no_build_required(self): self.assertFalse(os.path.exists(os.path.join(HERE, "package.json"))) def test_valid_html(self): - with open(os.path.join(HERE, "index.html")) as f: + with open(os.path.join(HERE, "index.html"), encoding="utf-8") as f: html = f.read() self.assertIn("", html) self.assertIn("", html)