Skip to content

Commit 0d51a1c

Browse files
JihaoXinclaude
andcommitted
Skip security tests when webapp deps are not installed
CI only installs base dependencies; importing ark.webapp.crypto triggers fastapi import via ark/webapp/__init__.py. Add pytest.importorskip guards so the test file is skipped gracefully. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
1 parent 4849ae0 commit 0d51a1c

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

tests/test_security.py

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,9 @@
55
import tempfile
66
from pathlib import Path
77

8+
pytest.importorskip("cryptography", reason="webapp optional deps not installed")
9+
pytest.importorskip("fastapi", reason="webapp optional deps not installed")
10+
811
from ark.webapp.crypto import encrypt_text, decrypt_text
912

1013
class TestCredentialSecurity:

0 commit comments

Comments
 (0)