标签:and iter computed == print mit none down 通过
import unittest
import numpy as np
class TestStudent(unittest.TestCase):
def setUp(self):
self.foo = Foo()
self.dataset = np.loadtxt("demo_train", delimiter=',')
def tearDown(self):
self.foo = None
#通过
def test_computeDistance(self):
result = self.foo.computeDistance([-0.64199,-0.63819,-0.63826], self.dataset)
print(result)
self.assertEqual(1, 1)
def test_rand_score(self):
result = self.foo.rand_score([1,0,0,1,2],[1,0,0,1,2])
self.assertEqual(1, 1)
if name == ‘main‘:
unittest.main()
标签:and iter computed == print mit none down 通过
原文地址:https://www.cnblogs.com/cccccttttyyy/p/12217247.html