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

Side by Side Diff: tools/perf/metrics/timeline_based_metric_request_unittest.py

Issue 165673008: [telemetry] Implement first version of timeline based measurement (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 6 years, 10 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 unified diff | Download patch | Annotate | Revision Log
OLDNEW
(Empty)
1 # Copyright 2014 The Chromium Authors. All rights reserved.
2 # Use of this source code is governed by a BSD-style license that can be
3 # found in the LICENSE file.
4
5 import unittest
6
7 from metrics import timeline_based_metric_request as tbmr_module
8
9
10 class ParseTests(unittest.TestCase):
11 def testParse(self):
12 self.assertTrue(tbmr_module.IsTimelineMetricRequest(
13 "MetricRequest.Foo/Bar"))
14 self.assertFalse(tbmr_module.IsTimelineMetricRequest(
15 "SomethingRandom"))
16
17 self.assertEquals(
18 ('LogicalName', 'MetricType'),
19 tbmr_module.ParseTimelineMetricRequest(
20 "MetricRequest.LogicalName/MetricType"))
21
22 self.assertEquals(
23 ('LogicalNameWith/Slash', 'MetricType'),
24 tbmr_module.ParseTimelineMetricRequest(
25 "MetricRequest.LogicalNameWith/Slash/MetricType"))
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698