def test_sexmachine_bernoulliNB_load(self):
     s = DameSexmachine()
     m = s.bernoulliNB_load()
     predicted = m.predict([[
         0, 0, 1, 0, 21, 0, 0, 0, 0, 34, 2, 0, 0, 0, 0, 0, 0, 0, 0, 5, 0, 0,
         0, 0, 0, 2, 0, 0, 0, 34, 1, 0, 1
     ]])
     n = np.array([2])
     self.assertTrue(np.array_equal(predicted, n))
Example #2
0
 def test_sexmachine_bernoulliNB_load_method_returns_correct_result(self):
     s = DameSexmachine()
     m = s.bernoulliNB_load()
     predicted = m.predict([[ 0,  0,  1,  0, 21,  0,  0,  0,  0, 34,  2,  0,  0,  0,  0,  0, 0,  0,  0,  5,  0,  0,  0,  0,  0,  2,  0,  0,  0, 34,  1,  0, 1, 0]])
     n = np.array([2])
     self.assertTrue(np.array_equal(predicted, n))