Get baseline 100% clean coverage (#1553)

This commit is contained in:
Max Isbey 2025-11-11 13:09:32 +00:00 • committed by GitHub
commit 89e9c43acf
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -19,9 +19,9 @@ def temp_file():
f.write(content)
path = Path(f.name).resolve()
yield path
try:
try: # pragma: no cover
path.unlink()
except FileNotFoundError:
except FileNotFoundError: # pragma: no cover
pass # File was already deleted by the test
@ -102,7 +102,7 @@ class TestFileResource:
@pytest.mark.skipif(os.name == "nt", reason="File permissions behave differently on Windows")
@pytest.mark.anyio
async def test_permission_error(self, temp_file: Path):
async def test_permission_error(self, temp_file: Path): # pragma: no cover
"""Test reading a file without permissions."""
temp_file.chmod(0o000) # Remove all permissions
try: