Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(194)

Unified Diff: tools/telemetry/telemetry/page/csv_page_measurement_results_unittest.py

Issue 22754003: Refactor BenchmarkResult.Add to take enum for data_type (Closed) Base URL: http://src.chromium.org/svn/trunk/src/
Patch Set: Created 7 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: tools/telemetry/telemetry/page/csv_page_measurement_results_unittest.py
===================================================================
--- tools/telemetry/telemetry/page/csv_page_measurement_results_unittest.py (revision 222891)
+++ tools/telemetry/telemetry/page/csv_page_measurement_results_unittest.py (working copy)
@@ -6,9 +6,14 @@
import os
import unittest
+from telemetry.core import util
from telemetry.page import csv_page_measurement_results
from telemetry.page import page_set
+# Get build scripts into our path.
+util.AddDirToPythonPath(util.GetChromiumSrcDir(), 'build', 'util', 'lib')
+from common import perf_result_data_type # pylint: disable=F0401
+
def _MakePageSet():
return page_set.PageSet.FromDict({
"description": "hello",
@@ -107,13 +112,13 @@
results.WillMeasurePage(self._page_set[0])
results.Add('a', '',
'{"buckets": [{"low": 1, "high": 2, "count": 1}]}',
- data_type='histogram')
+ data_type=perf_result_data_type.HISTOGRAM)
results.DidMeasurePage()
results.WillMeasurePage(self._page_set[1])
results.Add('a', '',
'{"buckets": [{"low": 2, "high": 3, "count": 1}]}',
- data_type='histogram')
+ data_type=perf_result_data_type.HISTOGRAM)
results.DidMeasurePage()
results.PrintSummary()

Powered by Google App Engine
This is Rietveld 408576698