From 9a5dce3dd4478c3fccc35eaaa12947c0952ad9a1 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E7=B3=96=E9=9C=B2=E6=98=9F=E9=9C=9C=E2=80=A2=E6=9A=96?= =?UTF-8?q?=E9=9C=9E=E6=8B=BE=E5=85=89?= <2468001320@qq.com> Date: Sat, 15 Aug 2026 02:58:56 +0800 Subject: [PATCH] fix: replace bare except with except Exception --- tests/test_helpers.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/tests/test_helpers.py b/tests/test_helpers.py index 2f755272..9efdb933 100644 --- a/tests/test_helpers.py +++ b/tests/test_helpers.py @@ -129,6 +129,7 @@ def test_bulk_emails_skip_comments_blank_lines(tmp_path, run_main, capsys): assert exit_code == 0 +@pytest.mark.skipif(sys.platform == "win32", reason="chmod(0) does not make files unreadable on Windows") def test_email_file_unreadable(tmp_path, run_main): email_file = tmp_path / "test_emails.txt" email_file.write_text("user@example.com") @@ -187,6 +188,7 @@ def test_bulk_usernames_skip_comments_blank_lines(tmp_path, run_main, capsys): assert exit_code == 0 +@pytest.mark.skipif(sys.platform == "win32", reason="chmod(0) does not make files unreadable on Windows") def test_username_file_unreadable(tmp_path, run_main): username_file = tmp_path / "test_usernames.txt" username_file.write_text("user")