diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index fa22922..a6236e4 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -20,14 +20,15 @@ jobs: runs-on: ubuntu-latest strategy: matrix: - python-version: ["3.9", "3.10"] + python-version: ["3.9", "3.10", "3.11", "3.12"] steps: - uses: actions/checkout@v2 - name: Set up Python ${{ matrix.python-version }} - uses: actions/setup-python@v1 + uses: actions/setup-python@v3 with: python-version: ${{ matrix.python-version }} + allow-prereleases: true - name: Install dependencies run: | python -m pip install --upgrade pip diff --git a/setup.py b/setup.py index ba91c96..e5a7198 100755 --- a/setup.py +++ b/setup.py @@ -33,7 +33,6 @@ def get_version(): "pytest-cov", "pytest-regressions", "pygments", - "sphinx_testing", "bs4", "rinohtype", ], diff --git a/tests/conftest.py b/tests/conftest.py index f776f49..e6d450a 100644 --- a/tests/conftest.py +++ b/tests/conftest.py @@ -3,7 +3,6 @@ from pathlib import Path from bs4 import BeautifulSoup import sphinx -from sphinx.testing.path import path from sphinx_tabs.tabs import FILES @@ -19,7 +18,7 @@ def pytest_configure(config): @pytest.fixture(scope="session") def rootdir(): """Pytest uses this to find test documents.""" - return path(__file__).parent.abspath() / "roots" + return Path(__file__).parent.absolute() / "roots" @pytest.fixture(autouse=True) @@ -117,7 +116,7 @@ def read(app, docname="index", resolve=False, regress=False, replace=None): extension = ".xml" # convert absolute filenames - for node in doctree.traverse(lambda n: "source" in n): + for node in doctree.findall(lambda n: "source" in n): node["source"] = Path(node["source"]).name if regress: