We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 7a2e37f commit c6531b7Copy full SHA for c6531b7
1 file changed
tests/test_5_parametric.py
@@ -17,10 +17,15 @@
17
def test_rtanalysis_parameteric(meanRT, sdRT, meanAcc):
18
test_df = generate_test_df(meanRT, sdRT, meanAcc)
19
rta = RTAnalysis()
20
- if meanAcc > 0:
+ if min(test_df.rt) <= 0:
21
+ # make sure it catches the rt < 0 error
22
+ with pytest.raises(ValueError):
23
+ rta.fit(test_df.rt, test_df.accuracy)
24
+ elif meanAcc > 0:
25
rta.fit(test_df.rt, test_df.accuracy)
26
assert np.allclose(meanRT, rta.mean_rt_)
27
assert np.allclose(meanAcc, rta.mean_accuracy_)
28
else:
29
+ # make sure it catches the zero accuracy error
30
with pytest.raises(ValueError):
31
0 commit comments