OLD | NEW |
1 # Copyright 2014 The Chromium Authors. All rights reserved. | 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 | 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 | 4 |
5 # | 5 # |
6 # Most of this file was ported over from Blink's | 6 # Most of this file was ported over from Blink's |
7 # webkitpy/layout_tests/layout_package/json_results_generator_unittest.py | 7 # webkitpy/layout_tests/layout_package/json_results_generator_unittest.py |
8 # | 8 # |
9 | 9 |
10 import unittest | 10 import unittest |
11 import json | 11 import json |
12 | 12 |
13 from pylib.utils import json_results_generator | 13 from pylib.results.flakiness_dashboard import json_results_generator |
14 | 14 |
15 | 15 |
16 class JSONGeneratorTest(unittest.TestCase): | 16 class JSONGeneratorTest(unittest.TestCase): |
17 | 17 |
18 def setUp(self): | 18 def setUp(self): |
19 self.builder_name = 'DUMMY_BUILDER_NAME' | 19 self.builder_name = 'DUMMY_BUILDER_NAME' |
20 self.build_name = 'DUMMY_BUILD_NAME' | 20 self.build_name = 'DUMMY_BUILD_NAME' |
21 self.build_number = 'DUMMY_BUILDER_NUMBER' | 21 self.build_number = 'DUMMY_BUILDER_NUMBER' |
22 | 22 |
23 # For archived results. | 23 # For archived results. |
(...skipping 180 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
204 expected_trie = { | 204 expected_trie = { |
205 'bar.html': 0, | 205 'bar.html': 0, |
206 'foo': { | 206 'foo': { |
207 'bar': { | 207 'bar': { |
208 'baz.html': 1200, | 208 'baz.html': 1200, |
209 } | 209 } |
210 } | 210 } |
211 } | 211 } |
212 | 212 |
213 self.assertEqual(json.dumps(trie), json.dumps(expected_trie)) | 213 self.assertEqual(json.dumps(trie), json.dumps(expected_trie)) |
OLD | NEW |