diff --git a/.github/workflows/tests-docs.yaml b/.github/workflows/tests-docs.yaml index 956481d1..ef9aa831 100644 --- a/.github/workflows/tests-docs.yaml +++ b/.github/workflows/tests-docs.yaml @@ -35,9 +35,12 @@ jobs: - name: Install run: | - uv sync --group tests + uv sync --group tests --extra mistral - name: Run Documentation tests + env: + MISTRAL_API_KEY: ${{ secrets.MISTRAL_API_KEY }} + OPENAI_API_KEY: ${{ secrets.OPENAI_API_KEY }} run: pytest tests/docs -v --cov --cov-report=xml - name: Upload coverage reports to Codecov diff --git a/tests/docs/test_all.py b/tests/docs/test_all.py index 351cd647..5ef109a2 100644 --- a/tests/docs/test_all.py +++ b/tests/docs/test_all.py @@ -1,6 +1,4 @@ import pathlib -from typing import Any -from unittest.mock import patch import pytest from mktestdocs import check_md_file @@ -11,9 +9,5 @@ list(pathlib.Path("docs").glob("**/*.md")), ids=str, ) -def test_all_docs(doc_file: pathlib.Path, monkeypatch: Any) -> None: - monkeypatch.setenv("MISTRAL_API_KEY", "test_key") - with ( - patch("any_llm.any_llm.AnyLLM.create"), - ): - check_md_file(fpath=doc_file, memory=True) # type: ignore[no-untyped-call] +def test_all_docs(doc_file: pathlib.Path) -> None: + check_md_file(fpath=doc_file, memory=True) # type: ignore[no-untyped-call]