Esempio n. 1
0
 def test_simple_average_has_count(self):
     count = 10
     average = simple_average()
     for element in range(0,count):
         average.calculate(element)
     self.assertEquals(average.count, count)
Esempio n. 2
0
 def test_simple_average_has_count(self):
     count = 10
     average = simple_average()
     for element in range(0, count):
         average.calculate(element)
     self.assertEquals(average.count, count)
Esempio n. 3
0
 def test_simple_average(self):
     average = simple_average()
     rv = 0
     for element in self.elements:
         rv = average.calculate(element)
     self.assertEquals(rv, 4.714285714285714)
Esempio n. 4
0
 def test_simple_average(self):
     average = simple_average()
     rv = 0
     for element in self.elements:
         rv = average.calculate(element)
     self.assertEquals(rv, 4.714285714285714)