Skip to content

Commit

Permalink
Moved RapidtideDataset tests all to test_zRapidtideDataset
Browse files Browse the repository at this point in the history
  • Loading branch information
bbfrederick committed Nov 2, 2023
1 parent b0cb257 commit bbd319c
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 19 deletions.
18 changes: 0 additions & 18 deletions rapidtide/tests/test_fullrunrapidtide_v1.py
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,6 @@

import rapidtide.workflows.rapidtide as rapidtide_workflow
import rapidtide.workflows.rapidtide_parser as rapidtide_parser
from rapidtide.RapidtideDataset import RapidtideDataset
from rapidtide.tests.utils import get_examples_path, get_test_temp_path


Expand All @@ -42,23 +41,6 @@ def test_fullrunrapidtide_v1(debug=False, displayplots=False):
]
rapidtide_workflow.rapidtide_main(rapidtide_parser.process_args(inputargs=inputargs))

datafileroot = os.path.join(get_test_temp_path(), "sub-RAPIDTIDETEST1")
thedataset = RapidtideDataset(
"main",
datafileroot,
usecorrout=True,
verbose=True,
init_LUT=False,
)

assert thedataset.focusregressor == "prefilt"
thedataset.setfocusregressor("pass3")
assert thedataset.focusregressor == "pass3"

if debug:
print(thedataset.regressorfilterlimits)
assert thedataset.regressorfilterlimits == (0.01, 0.15)


if __name__ == "__main__":
mpl.use("TkAgg")
Expand Down
10 changes: 9 additions & 1 deletion rapidtide/tests/test_zRapidtideDataset.py
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ def main(runninglocally=False):
datafileroot = "../data/examples/dst/sub-RAPIDTIDETEST_"
else:
print(f"get_test_temp_path={get_test_temp_path()}")
datafileroot = (os.path.join(get_test_temp_path(), "sub-RAPIDTIDETEST2_"),)
datafileroot = (os.path.join(get_test_temp_path(), "sub-RAPIDTIDETEST1_"),)
anatname = None
geommaskname = None
userise = False
Expand Down Expand Up @@ -62,6 +62,14 @@ def main(runninglocally=False):
theoverlays = thesubject.getoverlays()
theregressors = thesubject.getregressors()

assert thesubject.focusregressor == "prefilt"
thesubject.setfocusregressor("pass3")
assert thesubject.focusregressor == "pass3"

if debug:
print(thesubject.regressorfilterlimits)
assert thesubject.regressorfilterlimits == (0.01, 0.15)


if __name__ == "__main__":
main(runninglocally=True)

0 comments on commit bbd319c

Please sign in to comment.