Coverage for transformer_lens/model_bridge/sources/inspect/conftest.py: 0%
3 statements
« prev ^ index » next coverage.py v7.10.1, created at 2026-09-21 19:27 +0000
« prev ^ index » next coverage.py v7.10.1, created at 2026-09-21 19:27 +0000
1"""Skip doctest-modules collection of inspect-provider files when ``inspect_ai`` is not
2installed (it's an optional extra). Each file does a top-level ``from inspect_ai.model
3import …`` for the ``ModelAPI`` base + helper types — guarding that import per-file would
4bury the dependency contract; one collect-time skip here keeps the providers' source clean
5and lets ``make docstring-test`` run cleanly without the ``inspect`` extra."""
6from __future__ import annotations
8from importlib import util as _importlib_util
10collect_ignore_glob = (
11 []
12 if _importlib_util.find_spec("inspect_ai") is not None
13 else [
14 "_provider_base.py",
15 "eval.py",
16 "transformers_provider.py",
17 "vllm_provider.py",
18 ]
19)