Skip to content

Commit 2cee211

Browse files
committed
Avoid to test FunctionSampler in common test
1 parent e310fa7 commit 2cee211

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

imblearn/utils/estimator_checks.py

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -35,6 +35,8 @@
3535

3636
from imblearn.utils.testing import warns
3737

38+
NOT_TESTED_SAMPLERS = ('FunctionSampler') # This is not a normal sampler
39+
3840

3941
def _yield_sampler_checks(name, Estimator):
4042
yield check_target_type
@@ -76,7 +78,8 @@ def check_estimator(Estimator):
7678
sklearn_check_estimator(Estimator)
7779
check_parameters_default_constructible(name, Estimator)
7880
for check in _yield_all_checks(name, Estimator):
79-
check(name, Estimator)
81+
if name not in NOT_TESTED_SAMPLERS:
82+
check(name, Estimator)
8083

8184

8285
def check_target_type(name, Estimator):

0 commit comments

Comments
 (0)