diff --git a/tests/test_review/test_state.py b/tests/test_review/test_state.py index 31684e43..348d0c7c 100644 --- a/tests/test_review/test_state.py +++ b/tests/test_review/test_state.py @@ -3,6 +3,7 @@ Tests for review.state module. """ import json +import sys from pathlib import Path from unittest.mock import MagicMock, patch from datetime import datetime @@ -57,10 +58,11 @@ class TestComputeFileHash: hash2 = _compute_file_hash(file2) assert hash1 == hash2 + @pytest.mark.skipif(sys.platform == "win32", reason="Windows console cannot encode certain Unicode characters (charmap codec limitation)") def test_hash_unicode_content(self, tmp_path: Path) -> None: """Test computing hash of file with unicode content.""" test_file = tmp_path / "unicode.txt" - test_file.write_text("Hello δΈ–η•Œ 🌍") + test_file.write_text("Hello δΈ–η•Œ 🌍", encoding="utf-8") result = _compute_file_hash(test_file) assert result