| OLD | NEW |
| 1 # Copyright 2016 The Chromium Authors. All rights reserved. | 1 # Copyright 2016 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 import json | 5 import json |
| 6 import optparse | 6 import optparse |
| 7 import unittest | 7 import unittest |
| 8 | 8 |
| 9 from webkitpy.common.net.buildbot import Build | 9 from webkitpy.common.net.buildbot import Build |
| 10 from webkitpy.common.net.layout_test_results import LayoutTestResults | 10 from webkitpy.common.net.layout_test_results import LayoutTestResults |
| (...skipping 1169 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1180 | 1180 |
| 1181 def test_str_basic(self): | 1181 def test_str_basic(self): |
| 1182 test_baseline_set = TestBaselineSet(host=self.host) | 1182 test_baseline_set = TestBaselineSet(host=self.host) |
| 1183 test_baseline_set.add('a/x.html', Build('MOCK Mac10.12')) | 1183 test_baseline_set.add('a/x.html', Build('MOCK Mac10.12')) |
| 1184 test_baseline_set.add('a/x.html', Build('MOCK Win10')) | 1184 test_baseline_set.add('a/x.html', Build('MOCK Win10')) |
| 1185 self.assertEqual( | 1185 self.assertEqual( |
| 1186 str(test_baseline_set), | 1186 str(test_baseline_set), |
| 1187 ('<TestBaselineSet with:\n' | 1187 ('<TestBaselineSet with:\n' |
| 1188 ' a/x.html: Build(builder_name=\'MOCK Mac10.12\', build_number=Non
e), test-mac-mac10.12\n' | 1188 ' a/x.html: Build(builder_name=\'MOCK Mac10.12\', build_number=Non
e), test-mac-mac10.12\n' |
| 1189 ' a/x.html: Build(builder_name=\'MOCK Win10\', build_number=None),
test-win-win10>')) | 1189 ' a/x.html: Build(builder_name=\'MOCK Win10\', build_number=None),
test-win-win10>')) |
| 1190 |
| 1191 def test_getters(self): |
| 1192 test_baseline_set = TestBaselineSet(host=self.host) |
| 1193 test_baseline_set.add('a/x.html', Build('MOCK Mac10.12')) |
| 1194 test_baseline_set.add('a/x.html', Build('MOCK Win10')) |
| 1195 self.assertEqual(test_baseline_set.test_prefixes(), ['a/x.html']) |
| 1196 self.assertEqual( |
| 1197 test_baseline_set.build_port_pairs('a/x.html'), |
| 1198 [ |
| 1199 (Build(builder_name='MOCK Mac10.12'), 'test-mac-mac10.12'), |
| 1200 (Build(builder_name='MOCK Win10'), 'test-win-win10') |
| 1201 ]) |
| OLD | NEW |