Skip to content

Commit 66a5bf3

Browse files
better test
1 parent 1fccb93 commit 66a5bf3

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

lifelines/tests/test_estimation.py

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2962,7 +2962,10 @@ def test_fit_kwargs_works_for_semiparametric(self, cph, rossi, capfd):
29622962
assert "step_size = 0.1000" in out
29632963

29642964
def test_fit_kwargs_works_for_spline_model(self, cph_spline, rossi, capfd):
2965-
cph_spline.fit(rossi, "week", "arrest", fit_options={"step_size": 0.1}, show_progress=True)
2965+
with pytest.raises(ConvergenceError):
2966+
cph_spline.fit(rossi, "week", "arrest", fit_options={"maxiter": 10}, show_progress=True)
2967+
2968+
cph_spline.fit(rossi, "week", "arrest", fit_options={"maxiter": 1000}, show_progress=True)
29662969
assert True
29672970

29682971
def test_parametric_models_can_do_interval_censoring(self, cph_spline, cph_pieces):

0 commit comments

Comments
 (0)