Skip to content

Commit bf9abd9

Browse files
committed
Fix warnings in test_bootstrap_existing_outcomes by changing test input
1 parent 6ffb451 commit bf9abd9

File tree

1 file changed

+7
-9
lines changed

1 file changed

+7
-9
lines changed

tests/estimagic/test_bootstrap.py

+7-9
Original file line numberDiff line numberDiff line change
@@ -123,18 +123,16 @@ def test_bootstrap_existing_outcomes(setup):
123123
result = bootstrap(
124124
data=setup["df"],
125125
outcome=_outcome_func,
126+
n_draws=3,
127+
)
128+
assert len(result.outcomes) == 3
129+
result = bootstrap(
130+
outcome=_outcome_func,
131+
data=setup["df"],
132+
existing_result=result,
126133
n_draws=2,
127134
)
128135
assert len(result.outcomes) == 2
129-
with pytest.warns(RuntimeWarning):
130-
# As there is only one draw, multiple warnings are raised that can be ignored
131-
result = bootstrap(
132-
outcome=_outcome_func,
133-
data=setup["df"],
134-
existing_result=result,
135-
n_draws=1,
136-
)
137-
assert len(result.outcomes) == 1
138136

139137

140138
def test_bootstrap_from_outcomes(setup, expected):

0 commit comments

Comments
 (0)