File tree Expand file tree Collapse file tree 2 files changed +7
-13
lines changed Expand file tree Collapse file tree 2 files changed +7
-13
lines changed Original file line number Diff line number Diff line change 31
31
# stdlib
32
32
import datetime
33
33
import itertools
34
+ import os
34
35
import random
35
36
import sys
36
37
from functools import lru_cache
@@ -391,6 +392,12 @@ def my_test(tmp_pathplus: PathPlus):
391
392
return PathPlus (tmp_path )
392
393
393
394
395
+ @pytest .fixture ()
396
+ def original_datadir (request ) -> Path :
397
+ # Work around pycharm confusing datadir with test file.
398
+ return Path (os .path .splitext (request .module .__file__ )[0 ] + '_' )
399
+
400
+
394
401
def pytest_report_header (config , startdir ):
395
402
"""
396
403
Prints the start time of the pytest session.
Original file line number Diff line number Diff line change 1
- # stdlib
2
- import os
3
- from pathlib import Path
4
-
5
- # 3rd party
6
- import pytest
7
-
8
1
pytest_plugins = ("domdf_python_tools.testing" , )
9
-
10
-
11
- @pytest .fixture ()
12
- def original_datadir (request ) -> Path :
13
- # Work around pycharm confusing datadir with test file.
14
- return Path (os .path .splitext (request .module .__file__ )[0 ] + '_' )
You can’t perform that action at this time.
0 commit comments