| Index: tools/perf/metrics/statistics_unittest.py
|
| diff --git a/tools/perf/metrics/statistics_unittest.py b/tools/perf/metrics/statistics_unittest.py
|
| index 78fe81ff1511a7d374c93728a6aee1b1f7a790a6..8b1ad62e7139ecc7fa9d3d37f9d39da15c75272c 100644
|
| --- a/tools/perf/metrics/statistics_unittest.py
|
| +++ b/tools/perf/metrics/statistics_unittest.py
|
| @@ -5,7 +5,7 @@
|
| import unittest
|
| import random
|
|
|
| -from metrics import statistics
|
| +from telemetry.util import statistics
|
|
|
|
|
| def Relax(samples, iterations=10):
|
| @@ -158,13 +158,10 @@ class StatisticsUnitTest(unittest.TestCase):
|
|
|
| def testArithmeticMean(self):
|
| # The ArithmeticMean function computes the simple average.
|
| - self.assertAlmostEquals(40/3.0, statistics.ArithmeticMean([10, 10, 20], 3))
|
| - self.assertAlmostEquals(15.0, statistics.ArithmeticMean([10, 20], 2))
|
| - # Both lists of values or single values can be given for either argument.
|
| - self.assertAlmostEquals(40/3.0, statistics.ArithmeticMean(40, [1, 1, 1]))
|
| + self.assertAlmostEquals(40/3.0, statistics.ArithmeticMean([10, 10, 20]))
|
| + self.assertAlmostEquals(15.0, statistics.ArithmeticMean([10, 20]))
|
| # If the 'count' is zero, then zero is returned.
|
| - self.assertEquals(0, statistics.ArithmeticMean(4.0, 0))
|
| - self.assertEquals(0, statistics.ArithmeticMean(4.0, []))
|
| + self.assertEquals(0, statistics.ArithmeticMean([]))
|
|
|
| def testDurationsDiscrepancy(self):
|
| durations = []
|
|
|