Skip to content

Commit 2132cde

Browse files
committed
test
1 parent 3a45cf8 commit 2132cde

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

tests/server/fastmcp/resources/test_file_resources.py

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -105,8 +105,10 @@ async def test_missing_file_error(self, temp_file: Path):
105105
os.name == "nt", reason="File permissions behave differently on Windows"
106106
)
107107
@pytest.mark.anyio
108-
async def test_permission_error(self, temp_file: Path):
108+
async def test_permission_error(temp_file: Path):
109109
"""Test reading a file without permissions."""
110+
if os.geteuid() == 0:
111+
pytest.skip("Permission test not reliable when running as root")
110112
temp_file.chmod(0o000) # Remove all permissions
111113
try:
112114
resource = FileResource(

0 commit comments

Comments
 (0)