-
Notifications
You must be signed in to change notification settings - Fork 45
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
2c603f9
commit 68eea61
Showing
1 changed file
with
8 additions
and
2 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,12 +1,18 @@ | ||
from pathlib import Path | ||
|
||
import pytest | ||
import sphinx | ||
|
||
if sphinx.version_info < (7,): | ||
from sphinx.testing.path import path | ||
_rootdir = path(__file__).parent.abspath() / 'roots' | ||
else: | ||
from pathlib import Path | ||
_rootdir = Path(__file__).parent.resolve() / 'roots' | ||
|
||
pytest_plugins = 'sphinx.testing.fixtures' | ||
collect_ignore = ['roots'] | ||
|
||
|
||
@pytest.fixture(scope='session') | ||
def rootdir() -> Path: | ||
return Path(__file__).parent.resolve() / 'roots' | ||
return _rootdir |