Exemplo n.º 1
0
 def test_10_1(self):
     "test toBeOne from recommend.py"
     data = [
         frozenset(['1', '2']),
         frozenset(['2', '3']),
         frozenset(['1', '2', '3', '4'])
     ]
     result = toBeOne(data)
     expectResult = ['1', '2', '3', '4']
     self.assertListEqual(result, expectResult, "toBeOne Error")
Exemplo n.º 2
0
 def test_10_2(self):
     "test toBeOne from recommend.py"
     data = []
     result = toBeOne(data)
     expectResult = []
     self.assertListEqual(result, expectResult, "toBeOne Error")
Exemplo n.º 3
0
 def test_10_4(self):
     "test toBeOne from recommend.py"
     data = [['1','2'],['2','3'],['1','2','3','4']]
     result = toBeOne(data)
     expectResult = ['1','2','3','4']
     self.assertListEqual(result,expectResult,"toBeOne Error")      
Exemplo n.º 4
0
 def test_10_2(self):
     "test toBeOne from recommend.py"
     data = []
     result = toBeOne(data)
     expectResult = []
     self.assertListEqual(result,expectResult,"toBeOne Error")