Chromium Code Reviews| OLD | NEW |
|---|---|
| 1 # Copyright (C) 2010 Google Inc. All rights reserved. | 1 # Copyright (C) 2010 Google Inc. All rights reserved. |
| 2 # | 2 # |
| 3 # Redistribution and use in source and binary forms, with or without | 3 # Redistribution and use in source and binary forms, with or without |
| 4 # modification, are permitted provided that the following conditions are | 4 # modification, are permitted provided that the following conditions are |
| 5 # met: | 5 # met: |
| 6 # | 6 # |
| 7 # * Redistributions of source code must retain the above copyright | 7 # * Redistributions of source code must retain the above copyright |
| 8 # notice, this list of conditions and the following disclaimer. | 8 # notice, this list of conditions and the following disclaimer. |
| 9 # * Redistributions in binary form must reproduce the above | 9 # * Redistributions in binary form must reproduce the above |
| 10 # copyright notice, this list of conditions and the following disclaimer | 10 # copyright notice, this list of conditions and the following disclaimer |
| (...skipping 744 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 755 """ | 755 """ |
| 756 items = self._wpt_manifest()['items'] | 756 items = self._wpt_manifest()['items'] |
| 757 if path_in_wpt in items['manual']: | 757 if path_in_wpt in items['manual']: |
| 758 return items['manual'][path_in_wpt] | 758 return items['manual'][path_in_wpt] |
| 759 elif path_in_wpt in items['reftest']: | 759 elif path_in_wpt in items['reftest']: |
| 760 return items['reftest'][path_in_wpt] | 760 return items['reftest'][path_in_wpt] |
| 761 elif path_in_wpt in items['testharness']: | 761 elif path_in_wpt in items['testharness']: |
| 762 return items['testharness'][path_in_wpt] | 762 return items['testharness'][path_in_wpt] |
| 763 return None | 763 return None |
| 764 | 764 |
| 765 def is_slow_wpt_test(self, test_file): | |
| 766 match = re.search(r'external/wpt/(.*)$', test_file) | |
|
qyearsley
2017/01/25 19:16:45
If test_file is always relative to LayoutTests, th
tkent
2017/01/25 23:25:12
Done.
| |
| 767 if not match: | |
| 768 return False | |
| 769 items = self._manifest_items_for_path(match.group(1)) | |
| 770 if items is None or len(items) == 0: | |
|
qyearsley
2017/01/25 19:16:45
This could also (optionally) be:
if not items: .
tkent
2017/01/25 23:25:12
Done.
| |
| 771 return False | |
| 772 options = items[0][1] | |
|
qyearsley
2017/01/25 19:16:45
Depending on the type of test, this will be either
tkent
2017/01/25 23:25:12
Done.
BTW, I found the field was called "extras" i
| |
| 773 return 'timeout' in options and options['timeout'] == 'long' | |
| 774 | |
| 765 ALL_TEST_TYPES = ['audio', 'harness', 'pixel', 'ref', 'text', 'unknown'] | 775 ALL_TEST_TYPES = ['audio', 'harness', 'pixel', 'ref', 'text', 'unknown'] |
| 766 | 776 |
| 767 def test_type(self, test_name): | 777 def test_type(self, test_name): |
| 768 fs = self._filesystem | 778 fs = self._filesystem |
| 769 if fs.exists(self.expected_filename(test_name, '.png')): | 779 if fs.exists(self.expected_filename(test_name, '.png')): |
| 770 return 'pixel' | 780 return 'pixel' |
| 771 if fs.exists(self.expected_filename(test_name, '.wav')): | 781 if fs.exists(self.expected_filename(test_name, '.wav')): |
| 772 return 'audio' | 782 return 'audio' |
| 773 if self.reference_files(test_name): | 783 if self.reference_files(test_name): |
| 774 return 'ref' | 784 return 'ref' |
| (...skipping 870 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 1645 | 1655 |
| 1646 def __init__(self, base, args, reference_args=None): | 1656 def __init__(self, base, args, reference_args=None): |
| 1647 self.name = base | 1657 self.name = base |
| 1648 self.base = base | 1658 self.base = base |
| 1649 self.args = args | 1659 self.args = args |
| 1650 self.reference_args = args if reference_args is None else reference_args | 1660 self.reference_args = args if reference_args is None else reference_args |
| 1651 self.tests = set() | 1661 self.tests = set() |
| 1652 | 1662 |
| 1653 def __repr__(self): | 1663 def __repr__(self): |
| 1654 return "PhysicalTestSuite('%s', '%s', %s, %s)" % (self.name, self.base, self.args, self.reference_args) | 1664 return "PhysicalTestSuite('%s', '%s', %s, %s)" % (self.name, self.base, self.args, self.reference_args) |
| OLD | NEW |