Files
AI/참고/instructor-main/tests/llm/test_anthropic/conftest.py

17 lines
395 B
Python
Raw Normal View History

2026-05-12 19:40:31 +09:00
# conftest.py
import os
import pytest
import importlib.util
if not os.getenv("ANTHROPIC_API_KEY"):
pytest.skip(
"ANTHROPIC_API_KEY environment variable not set",
allow_module_level=True,
)
if (
importlib.util.find_spec("anthropic") is None
): # pragma: no cover - optional dependency
pytest.skip("anthropic package is not installed", allow_module_level=True)