def test_iht_fit_sample_wrong_class_obj():
 from sklearn.cluster import KMeans
 est = KMeans()
 iht = InstanceHardnessThreshold(estimator=est, random_state=RND_SEED)
 assert_raises(ValueError, iht.fit_sample, X, Y)

def test_iht_fit_sample_wrong_class_obj ( ) : from sklearn . cluster import KMeans est = KMeans ( ) iht = InstanceHardnessThreshold ( estimator = est , random_state = RND_SEED ) assert_raises ( ValueError , iht . fit_sample , X , Y )
test either if an error is raised while passing a wrong classifier object .