mirror of
https://github.com/MadsLorentzen/ai-job-search.git
synced 2026-11-02 13:12:50 +00:00
test(verify_pdf): skip the symlink refusal check where symlinks need a privilege
On Windows, Path.symlink_to raises WinError 1314 for a user without Developer Mode or admin rights, which turned the test into an error on a developer machine. GitHub's Windows runners create symlinks fine, so CI still exercises it; elsewhere the test now skips with the reason. Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
This commit is contained in:
1 parent
ae6c5aded5
commit
d83945f136
1 file changed
+4
-1
@@ -364,7 +364,10 @@ class DumpTargetTests(unittest.TestCase):
|
||||
|
||||
def test_symlink_out_of_cv_is_refused(self):
|
||||
link = self.root / "cv" / "main_acme.txt"
|
||||
link.symlink_to(self.root / "outside.txt")
|
||||
try:
|
||||
link.symlink_to(self.root / "outside.txt")
|
||||
except OSError as exc: # Windows without Developer Mode or admin rights (WinError 1314)
|
||||
self.skipTest(f"cannot create symlinks here: {exc}")
|
||||
self.assertEqual(check_dump_target(link, self.root), "must not be a symlink")
|
||||
|
||||
@patch("tools.verify_pdf.verify_pdf")
|
||||
|
||||
Reference in new issue
Block a user