示例#1
0
 def test_FitTransform__predict(self):
     X = self.X
     sc = MinMaxScaler()
     sc.__class__ = type('newClass', (type(sc), FitTransformMixin), {})
     sc.fit_using_varargs(X=X)
     result_sc = sc.predict_dict(X=X)
     self.assertEqual(list(result_sc.keys()), ['predict'])
     self.assertEqual(result_sc['predict'].shape, (self.size, 1))
示例#2
0
 def test_FitTransform__get_predict_signature(self):
     sc = MinMaxScaler()
     sc.__class__ = type('newClass', (type(sc), FitTransformMixin), {})
     result_sc = sc._get_predict_signature()
     self.assertEqual(result_sc, ['X'])