Esempio n. 1
0
 def test6_netflixPrediction(self):
     r = StringIO.StringIO('')
     output = netflixPredictions(r)
     self.assertEqual(len(output), 0)
Esempio n. 2
0
 def test5_netflixPrediction(self):
     r = StringIO.StringIO('6704:\n1455188\n6706:\n2634386\n6704:\n977462\n525889\n3821:\n')
     output = netflixPredictions(r)
     self.assertIsInstance(output[0], str)
     self.assertIsInstance(output[4], str)
Esempio n. 3
0
 def test4_netflixPrediction(self):
     r = StringIO.StringIO('1316:\n13160:\n13163:\n13166:\n13161:\n3821:\n')
     output = netflixPredictions(r)
     self.assertIsInstance(output[0], str)
     self.assertIsInstance(output[1], str)
Esempio n. 4
0
 def test3_netflixPrediction(self):
     r = StringIO.StringIO('1316:\n549913\n2161934\n13160:\n1212448\n13161:\n2438741\n')
     output = netflixPredictions(r)
     self.assertIsInstance(output[6], float)
Esempio n. 5
0
 def test2_netflixPrediction(self):
     r = StringIO.StringIO('1878:\n1646018\n1879:\n113983\n188:\n')
     output = netflixPredictions(r)
     self.assertIsInstance(output[4], str)
Esempio n. 6
0
 def test1_netflixPrediction(self):
     r = StringIO.StringIO('10004:\n2140798\n84804\n580:\n2591198\n1933')
     output = netflixPredictions(r)
     self.assertEqual(len(output), 6)