Changeset 176814 in webkit


Ignore:
Timestamp:
Dec 4, 2014 1:49:43 PM (9 years ago)
Author:
ap@apple.com
Message:

Don't lock perf tests in run-webkit-tests
https://bugs.webkit.org/show_bug.cgi?id=139264

Reviewed by Daniel Bates.

  • Scripts/webkitpy/layout_tests/controllers/layout_test_runner.py:
  • Scripts/webkitpy/layout_tests/controllers/layout_test_runner_unittest.py:
  • Scripts/webkitpy/layout_tests/controllers/manager.py:
  • Scripts/webkitpy/layout_tests/models/test_input.py:
  • Scripts/webkitpy/layout_tests/run_webkit_tests_integrationtest.py:
Location:
trunk/Tools
Files:
6 edited

Legend:

Unmodified
Added
Removed
  • trunk/Tools/ChangeLog

    r176800 r176814  
     12014-12-04  Alexey Proskuryakov  <ap@apple.com>
     2
     3        Don't lock perf tests in run-webkit-tests
     4        https://bugs.webkit.org/show_bug.cgi?id=139264
     5
     6        Reviewed by Daniel Bates.
     7
     8        * Scripts/webkitpy/layout_tests/controllers/layout_test_runner.py:
     9        * Scripts/webkitpy/layout_tests/controllers/layout_test_runner_unittest.py:
     10        * Scripts/webkitpy/layout_tests/controllers/manager.py:
     11        * Scripts/webkitpy/layout_tests/models/test_input.py:
     12        * Scripts/webkitpy/layout_tests/run_webkit_tests_integrationtest.py:
     13
    1142014-12-03  Alexey Proskuryakov  <ap@apple.com>
    215
  • trunk/Tools/Scripts/webkitpy/layout_tests/controllers/layout_test_runner.py

    r170637 r176814  
    443443        self.name = name
    444444        self.test_inputs = test_inputs
    445         self.requires_lock = test_inputs[0].requires_lock
     445        self.needs_servers = test_inputs[0].needs_servers
    446446
    447447    def __repr__(self):
    448         return "TestShard(name='%s', test_inputs=%s, requires_lock=%s'" % (self.name, self.test_inputs, self.requires_lock)
     448        return "TestShard(name='%s', test_inputs=%s, needs_servers=%s'" % (self.name, self.test_inputs, self.needs_servers)
    449449
    450450    def __eq__(self, other):
     
    483483        unlocked_inputs = []
    484484        for test_input in test_inputs:
    485             if test_input.requires_lock:
     485            if test_input.needs_servers:
    486486                locked_inputs.append(test_input)
    487487            else:
     
    507507            # matter, and the only other meaningful value would be the filename,
    508508            # which would be really redundant.
    509             if test_input.requires_lock:
     509            if test_input.needs_servers:
    510510                locked_shards.append(TestShard('.', [test_input]))
    511511            else:
     
    531531        for directory, test_inputs in tests_by_dir.iteritems():
    532532            shard = TestShard(directory, test_inputs)
    533             if test_inputs[0].requires_lock:
     533            if test_inputs[0].needs_servers:
    534534                locked_shards.append(shard)
    535535            else:
  • trunk/Tools/Scripts/webkitpy/layout_tests/controllers/layout_test_runner_unittest.py

    r174136 r176814  
    113113        self._run_tests(runner, ['http/tests/passes/text.html', 'passes/text.html'])
    114114
    115     def test_perf_locking(self):
    116         runner = self._runner()
    117         self._run_tests(runner, ['http/tests/passes/text.html', 'perf/foo/test.html'])
    118 
    119115    def test_interrupt_if_at_failure_limits(self):
    120116        runner = self._runner()
     
    234230        "ietestcenter/Javascript/11.1.5_4-4-c-1.html",
    235231        "dom/html/level2/html/HTMLAnchorElement06.html",
    236         "perf/object-keys.html",
    237232    ]
    238233
    239234    def get_test_input(self, test_file):
    240         return TestInput(test_file, requires_lock=(test_file.startswith('http') or test_file.startswith('perf')))
     235        return TestInput(test_file, needs_servers=(test_file.startswith('http')))
    241236
    242237    def get_shards(self, num_workers, fully_parallel, test_list=None, max_locked_shards=1):
     
    265260                'http/tests/websocket/tests/unicode.htm',
    266261                'http/tests/websocket/tests/websocket-protocol-ignored.html',
    267                 'http/tests/xmlhttprequest/supported-xml-content-types.html',
    268                 'perf/object-keys.html'])])
     262                'http/tests/xmlhttprequest/supported-xml-content-types.html'])])
    269263        self.assert_shards(unlocked,
    270264            [('animations', ['animations/keyframes.html']),
     
    280274             ('.', ['http/tests/security/view-source-no-refresh.html']),
    281275             ('.', ['http/tests/websocket/tests/websocket-protocol-ignored.html']),
    282              ('.', ['http/tests/xmlhttprequest/supported-xml-content-types.html']),
    283              ('.', ['perf/object-keys.html'])]),
     276             ('.', ['http/tests/xmlhttprequest/supported-xml-content-types.html'])]),
    284277        self.assert_shards(unlocked,
    285278            [('.', ['animations/keyframes.html']),
     
    296289               'http/tests/security/view-source-no-refresh.html',
    297290               'http/tests/websocket/tests/websocket-protocol-ignored.html',
    298                'http/tests/xmlhttprequest/supported-xml-content-types.html',
    299                'perf/object-keys.html'])])
     291               'http/tests/xmlhttprequest/supported-xml-content-types.html'])])
    300292        self.assert_shards(unlocked,
    301293            [('unlocked_tests',
     
    326318               'http/tests/websocket/tests/websocket-protocol-ignored.html']),
    327319             ('locked_shard_2',
    328               ['http/tests/xmlhttprequest/supported-xml-content-types.html',
    329                'perf/object-keys.html'])])
     320              ['http/tests/xmlhttprequest/supported-xml-content-types.html'])])
    330321
    331322        locked, unlocked = self.get_shards(num_workers=4, fully_parallel=False)
     
    335326               'http/tests/websocket/tests/unicode.htm',
    336327               'http/tests/websocket/tests/websocket-protocol-ignored.html',
    337                'http/tests/xmlhttprequest/supported-xml-content-types.html',
    338                'perf/object-keys.html'])])
     328               'http/tests/xmlhttprequest/supported-xml-content-types.html'])])
  • trunk/Tools/Scripts/webkitpy/layout_tests/controllers/manager.py

    r170637 r176814  
    7979
    8080        self.HTTP_SUBDIR = 'http' + port.TEST_PATH_SEPARATOR
    81         self.PERF_SUBDIR = 'perf'
    8281        self.WEBSOCKET_SUBDIR = 'websocket' + port.TEST_PATH_SEPARATOR
    8382        self.LAYOUT_TESTS_DIRECTORY = 'LayoutTests'
     
    102101    def _http_tests(self, test_names):
    103102        return set(test for test in test_names if self._is_http_test(test))
    104 
    105     def _is_perf_test(self, test):
    106         return self.PERF_SUBDIR == test or (self.PERF_SUBDIR + self._port.TEST_PATH_SEPARATOR) in test
    107103
    108104    def _prepare_lists(self, paths, test_names):
     
    126122        return TestInput(test_file,
    127123            self._options.slow_time_out_ms if self._test_is_slow(test_file) else self._options.time_out_ms,
    128             self._test_requires_lock(test_file))
    129 
    130     def _test_requires_lock(self, test_file):
    131         """Return True if the test needs to be locked when
    132         running multiple copies of NRWTs. Perf tests are locked
    133         because heavy load caused by running other tests in parallel
    134         might cause some of them to timeout."""
    135         return self._is_http_test(test_file) or self._is_perf_test(test_file)
     124            self._is_http_test(test_file))
    136125
    137126    def _test_is_slow(self, test_file):
     
    139128
    140129    def needs_servers(self, test_names):
    141         return any(self._test_requires_lock(test_name) for test_name in test_names) and self._options.http
     130        return any(self._is_http_test(test_name) for test_name in test_names) and self._options.http
    142131
    143132    def _set_up_run(self, test_names):
  • trunk/Tools/Scripts/webkitpy/layout_tests/models/test_input.py

    r136545 r176814  
    3232    """Groups information about a test for easy passing of data."""
    3333
    34     def __init__(self, test_name, timeout=None, requires_lock=None, reference_files=None, should_run_pixel_tests=None):
     34    def __init__(self, test_name, timeout=None, needs_servers=None, reference_files=None, should_run_pixel_tests=None):
    3535        # TestInput objects are normally constructed by the manager and passed
    3636        # to the workers, but these some fields are set lazily in the workers where possible
     
    3838        self.test_name = test_name
    3939        self.timeout = timeout  # in msecs; should rename this for consistency
    40         self.requires_lock = requires_lock
     40        self.needs_servers = needs_servers
    4141        self.reference_files = reference_files
    4242        self.should_run_pixel_tests = should_run_pixel_tests
    4343
    4444    def __repr__(self):
    45         return "TestInput('%s', timeout=%s, requires_lock=%s, reference_files=%s, should_run_pixel_tests=%s)" % (self.test_name, self.timeout, self.requires_lock, self.reference_files, self.should_run_pixel_tests)
     45        return "TestInput('%s', timeout=%s, needs_servers=%s, reference_files=%s, should_run_pixel_tests=%s)" % (self.test_name, self.timeout, self.needs_servers, self.reference_files, self.should_run_pixel_tests)
  • trunk/Tools/Scripts/webkitpy/layout_tests/run_webkit_tests_integrationtest.py

    r175204 r176814  
    340340
    341341    def test_no_order_with_directory_entries_in_natural_order(self):
    342         tests_to_run = ['http/tests/ssl', 'perf/foo', 'http/tests/passes']
     342        tests_to_run = ['http/tests/ssl', 'http/tests/passes']
    343343        tests_run = get_tests_run(['--order=none'] + tests_to_run)
    344         self.assertEqual(tests_run, ['http/tests/ssl/text.html', 'perf/foo/test.html', 'http/tests/passes/image.html', 'http/tests/passes/text.html'])
     344        self.assertEqual(tests_run, ['http/tests/ssl/text.html', 'http/tests/passes/image.html', 'http/tests/passes/text.html'])
    345345
    346346    def test_gc_between_tests(self):
Note: See TracChangeset for help on using the changeset viewer.