Skip to content

Commit

Permalink
Restore support in tests for Sphinx<7.2
Browse files Browse the repository at this point in the history
  • Loading branch information
AA-Turner committed Aug 9, 2023
1 parent 13329a9 commit 47d7318
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions tests/conftest.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,16 @@

import pytest

import sphinx

pytest_plugins = 'sphinx.testing.fixtures'


@pytest.fixture(scope='session')
def rootdir():
if sphinx.version_info[:2] < (7, 2):
from sphinx.testing.path import path

return path(__file__).parent.abspath() / 'roots'

return Path(__file__).resolve().parent / 'roots'

0 comments on commit 47d7318

Please sign in to comment.