Skip to content

Commit 3d61d5a

Browse files
TEST: add sklearn check_estimator test for MapieRegressor (#600)
1 parent 0f511e6 commit 3d61d5a

File tree

2 files changed

+7
-0
lines changed

2 files changed

+7
-0
lines changed

HISTORY.rst

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,7 @@ History
1919
* Documentation test: add a doc testing step (in MAKEFILE and CI)
2020
* Increase max line length from 79 to 88 characters
2121
* Bump wheel version
22+
* Other minor evolutions
2223

2324
0.9.1 (2024-09-13)
2425
------------------

mapie/tests/test_regression.py

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,7 @@
2020
)
2121
from sklearn.pipeline import Pipeline, make_pipeline
2222
from sklearn.preprocessing import OneHotEncoder
23+
from sklearn.utils.estimator_checks import check_estimator
2324
from sklearn.utils.validation import check_is_fitted
2425
from typing_extensions import TypedDict
2526

@@ -1039,3 +1040,8 @@ def test_deprecated_ensemble_regressor_fit_warning() -> None:
10391040
match=r".WARNING: EnsembleRegressor.fit is deprecated.*"
10401041
):
10411042
ens_reg.fit(X, y)
1043+
1044+
1045+
def test_mapie_regressor_sklearn_estim() -> None:
1046+
"""Test that MapieRegressor is an sklearn estimator"""
1047+
check_estimator(MapieRegressor())

0 commit comments

Comments
 (0)