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

Side by Side Diff: tools/telemetry/telemetry/page/block_page_benchmark_results_unittest.py

Issue 12278015: [Telemetry] Reorganize everything. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Re-add shebangs. Created 7 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
1 # Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 # Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 # Use of this source code is governed by a BSD-style license that can be 2 # Use of this source code is governed by a BSD-style license that can be
3 # found in the LICENSE file. 3 # found in the LICENSE file.
4 import StringIO 4 import StringIO
5 import os 5 import os
6 import unittest 6 import unittest
7 7
8 from telemetry import block_page_benchmark_results 8 from telemetry.page import block_page_benchmark_results
9 from telemetry.page_set import PageSet 9 from telemetry.page import page_set
10 10
11 BlockPageBenchmarkResults = \ 11 BlockPageBenchmarkResults = \
12 block_page_benchmark_results.BlockPageBenchmarkResults 12 block_page_benchmark_results.BlockPageBenchmarkResults
13 13
14 def _MakePageSet(): 14 def _MakePageSet():
15 return PageSet.FromDict({ 15 return page_set.PageSet.FromDict({
16 "description": "hello", 16 "description": "hello",
17 "archive_path": "foo.wpr", 17 "archive_path": "foo.wpr",
18 "pages": [ 18 "pages": [
19 {"url": "http://www.foo.com/"}, 19 {"url": "http://www.foo.com/"},
20 {"url": "http://www.bar.com/"} 20 {"url": "http://www.bar.com/"}
21 ] 21 ]
22 }, os.path.dirname(__file__)) 22 }, os.path.dirname(__file__))
23 23
24 class NonPrintingBlockPageBenchmarkResults(BlockPageBenchmarkResults): 24 class NonPrintingBlockPageBenchmarkResults(BlockPageBenchmarkResults):
25 def __init__(self, *args): 25 def __init__(self, *args):
(...skipping 28 matching lines...) Expand all
54 54
55 expected = [ 55 expected = [
56 ['url', 'http://www.foo.com/'], 56 ['url', 'http://www.foo.com/'],
57 ['foo (seconds)', '3'], 57 ['foo (seconds)', '3'],
58 [''], 58 [''],
59 ['url', 'http://www.bar.com/'], 59 ['url', 'http://www.bar.com/'],
60 ['bar (seconds)', '4'], 60 ['bar (seconds)', '4'],
61 [''] 61 ['']
62 ] 62 ]
63 self.assertEquals(self.data, expected) 63 self.assertEquals(self.data, expected)
OLDNEW
« no previous file with comments | « tools/telemetry/telemetry/page/block_page_benchmark_results.py ('k') | tools/telemetry/telemetry/page/click_element_action.py » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698