File tree Expand file tree Collapse file tree 2 files changed +11
-2
lines changed Expand file tree Collapse file tree 2 files changed +11
-2
lines changed Original file line number Diff line number Diff line change 1919import os
2020import re
2121import shutil
22+ import sys
2223from contextlib import contextmanager
24+ from distutils .version import LooseVersion
2325from typing import Any , Generator
2426
2527import git as gitpython
28+ import mkdocs
2629import pytest
2730from click .testing import CliRunner , Result
2831from git import Repo
@@ -318,7 +321,13 @@ def test_fallback(tmp_path) -> None:
318321 ), f"'mkdocs build' command failed. Error: { result .stdout } "
319322
320323
321- def test_mkapi (tmp_path ) -> None :
324+ # https://github.com/daizutabi/mkapi#:~:text=Python%203.10%20or,1.6%20or%20higher
325+ @pytest .mark .skipif (sys .version_info < (3 , 10 ), reason = "Requires Python 3.10 or higher" )
326+ @pytest .mark .skipif (
327+ LooseVersion (mkdocs .__version__ ) < LooseVersion ("1.6" ),
328+ reason = "Requires mkdocs 1.6 or higher" ,
329+ )
330+ def test_mkapi_v3 (tmp_path ) -> None :
322331 result = build_docs_setup ("tests/basic_setup/mkdocs_mkapi.yml" , tmp_path )
323332 assert (
324333 result .exit_code == 0
Original file line number Diff line number Diff line change @@ -16,4 +16,4 @@ mkdocs-git-revision-date-localized-plugin
1616mkdocs-material
1717
1818# mkapi
19- mkapi
19+ mkapi>=3
You can’t perform that action at this time.
0 commit comments