File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 99
1010import pytest
1111
12+ import shared
13+
1214# Import rimport module from file without .py extension
1315rimport_path = os .path .join (
1416 os .path .dirname (os .path .dirname (os .path .dirname (os .path .abspath (__file__ )))),
2325loader .exec_module (rimport )
2426
2527
28+ @pytest .fixture (scope = "function" , autouse = True )
29+ def fixture_temp_inputdata (temp_dirs ):
30+ """
31+ Override rimport's DEFAULT_INPUTDATA_ROOT to ensure portability.
32+
33+ We can't do it in tests/conftest.py's temp_dirs fixture because of how rimport is imported here;
34+ we'd get "no module rimport" errors. However, we can use the tempdir that got set up in that
35+ fixture.
36+ """
37+ rimport .DEFAULT_INPUTDATA_ROOT = shared .DEFAULT_INPUTDATA_ROOT
38+
39+
2640class TestBuildParser :
2741 """Test suite for build_parser() function."""
2842
You can’t perform that action at this time.
0 commit comments