<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN"
"http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head><meta http-equiv="content-type" content="text/html; charset=utf-8" />
<title>[176814] trunk/Tools</title>
</head>
<body>

<style type="text/css"><!--
#msg dl.meta { border: 1px #006 solid; background: #369; padding: 6px; color: #fff; }
#msg dl.meta dt { float: left; width: 6em; font-weight: bold; }
#msg dt:after { content:':';}
#msg dl, #msg dt, #msg ul, #msg li, #header, #footer, #logmsg { font-family: verdana,arial,helvetica,sans-serif; font-size: 10pt;  }
#msg dl a { font-weight: bold}
#msg dl a:link    { color:#fc3; }
#msg dl a:active  { color:#ff0; }
#msg dl a:visited { color:#cc6; }
h3 { font-family: verdana,arial,helvetica,sans-serif; font-size: 10pt; font-weight: bold; }
#msg pre { overflow: auto; background: #ffc; border: 1px #fa0 solid; padding: 6px; }
#logmsg { background: #ffc; border: 1px #fa0 solid; padding: 1em 1em 0 1em; }
#logmsg p, #logmsg pre, #logmsg blockquote { margin: 0 0 1em 0; }
#logmsg p, #logmsg li, #logmsg dt, #logmsg dd { line-height: 14pt; }
#logmsg h1, #logmsg h2, #logmsg h3, #logmsg h4, #logmsg h5, #logmsg h6 { margin: .5em 0; }
#logmsg h1:first-child, #logmsg h2:first-child, #logmsg h3:first-child, #logmsg h4:first-child, #logmsg h5:first-child, #logmsg h6:first-child { margin-top: 0; }
#logmsg ul, #logmsg ol { padding: 0; list-style-position: inside; margin: 0 0 0 1em; }
#logmsg ul { text-indent: -1em; padding-left: 1em; }#logmsg ol { text-indent: -1.5em; padding-left: 1.5em; }
#logmsg > ul, #logmsg > ol { margin: 0 0 1em 0; }
#logmsg pre { background: #eee; padding: 1em; }
#logmsg blockquote { border: 1px solid #fa0; border-left-width: 10px; padding: 1em 1em 0 1em; background: white;}
#logmsg dl { margin: 0; }
#logmsg dt { font-weight: bold; }
#logmsg dd { margin: 0; padding: 0 0 0.5em 0; }
#logmsg dd:before { content:'\00bb';}
#logmsg table { border-spacing: 0px; border-collapse: collapse; border-top: 4px solid #fa0; border-bottom: 1px solid #fa0; background: #fff; }
#logmsg table th { text-align: left; font-weight: normal; padding: 0.2em 0.5em; border-top: 1px dotted #fa0; }
#logmsg table td { text-align: right; border-top: 1px dotted #fa0; padding: 0.2em 0.5em; }
#logmsg table thead th { text-align: center; border-bottom: 1px solid #fa0; }
#logmsg table th.Corner { text-align: left; }
#logmsg hr { border: none 0; border-top: 2px dashed #fa0; height: 1px; }
#header, #footer { color: #fff; background: #636; border: 1px #300 solid; padding: 6px; }
#patch { width: 100%; }
#patch h4 {font-family: verdana,arial,helvetica,sans-serif;font-size:10pt;padding:8px;background:#369;color:#fff;margin:0;}
#patch .propset h4, #patch .binary h4 {margin:0;}
#patch pre {padding:0;line-height:1.2em;margin:0;}
#patch .diff {width:100%;background:#eee;padding: 0 0 10px 0;overflow:auto;}
#patch .propset .diff, #patch .binary .diff  {padding:10px 0;}
#patch span {display:block;padding:0 10px;}
#patch .modfile, #patch .addfile, #patch .delfile, #patch .propset, #patch .binary, #patch .copfile {border:1px solid #ccc;margin:10px 0;}
#patch ins {background:#dfd;text-decoration:none;display:block;padding:0 10px;}
#patch del {background:#fdd;text-decoration:none;display:block;padding:0 10px;}
#patch .lines, .info {color:#888;background:#fff;}
--></style>
<div id="msg">
<dl class="meta">
<dt>Revision</dt> <dd><a href="http://trac.webkit.org/projects/webkit/changeset/176814">176814</a></dd>
<dt>Author</dt> <dd>ap@apple.com</dd>
<dt>Date</dt> <dd>2014-12-04 13:49:43 -0800 (Thu, 04 Dec 2014)</dd>
</dl>

<h3>Log Message</h3>
<pre>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:</pre>

<h3>Modified Paths</h3>
<ul>
<li><a href="#trunkToolsChangeLog">trunk/Tools/ChangeLog</a></li>
<li><a href="#trunkToolsScriptswebkitpylayout_testscontrollerslayout_test_runnerpy">trunk/Tools/Scripts/webkitpy/layout_tests/controllers/layout_test_runner.py</a></li>
<li><a href="#trunkToolsScriptswebkitpylayout_testscontrollerslayout_test_runner_unittestpy">trunk/Tools/Scripts/webkitpy/layout_tests/controllers/layout_test_runner_unittest.py</a></li>
<li><a href="#trunkToolsScriptswebkitpylayout_testscontrollersmanagerpy">trunk/Tools/Scripts/webkitpy/layout_tests/controllers/manager.py</a></li>
<li><a href="#trunkToolsScriptswebkitpylayout_testsmodelstest_inputpy">trunk/Tools/Scripts/webkitpy/layout_tests/models/test_input.py</a></li>
<li><a href="#trunkToolsScriptswebkitpylayout_testsrun_webkit_tests_integrationtestpy">trunk/Tools/Scripts/webkitpy/layout_tests/run_webkit_tests_integrationtest.py</a></li>
</ul>

</div>
<div id="patch">
<h3>Diff</h3>
<a id="trunkToolsChangeLog"></a>
<div class="modfile"><h4>Modified: trunk/Tools/ChangeLog (176813 => 176814)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Tools/ChangeLog        2014-12-04 21:48:33 UTC (rev 176813)
+++ trunk/Tools/ChangeLog        2014-12-04 21:49:43 UTC (rev 176814)
</span><span class="lines">@@ -1,3 +1,16 @@
</span><ins>+2014-12-04  Alexey Proskuryakov  &lt;ap@apple.com&gt;
+
+        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:
+
</ins><span class="cx"> 2014-12-03  Alexey Proskuryakov  &lt;ap@apple.com&gt;
</span><span class="cx"> 
</span><span class="cx">         http/tests/security/mixedContent/about-blank-iframe-in-main-frame.html fails unless certain other tests run before it
</span></span></pre></div>
<a id="trunkToolsScriptswebkitpylayout_testscontrollerslayout_test_runnerpy"></a>
<div class="modfile"><h4>Modified: trunk/Tools/Scripts/webkitpy/layout_tests/controllers/layout_test_runner.py (176813 => 176814)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Tools/Scripts/webkitpy/layout_tests/controllers/layout_test_runner.py        2014-12-04 21:48:33 UTC (rev 176813)
+++ trunk/Tools/Scripts/webkitpy/layout_tests/controllers/layout_test_runner.py        2014-12-04 21:49:43 UTC (rev 176814)
</span><span class="lines">@@ -442,10 +442,10 @@
</span><span class="cx">     def __init__(self, name, test_inputs):
</span><span class="cx">         self.name = name
</span><span class="cx">         self.test_inputs = test_inputs
</span><del>-        self.requires_lock = test_inputs[0].requires_lock
</del><ins>+        self.needs_servers = test_inputs[0].needs_servers
</ins><span class="cx"> 
</span><span class="cx">     def __repr__(self):
</span><del>-        return &quot;TestShard(name='%s', test_inputs=%s, requires_lock=%s'&quot; % (self.name, self.test_inputs, self.requires_lock)
</del><ins>+        return &quot;TestShard(name='%s', test_inputs=%s, needs_servers=%s'&quot; % (self.name, self.test_inputs, self.needs_servers)
</ins><span class="cx"> 
</span><span class="cx">     def __eq__(self, other):
</span><span class="cx">         return self.name == other.name and self.test_inputs == other.test_inputs
</span><span class="lines">@@ -482,7 +482,7 @@
</span><span class="cx">         locked_inputs = []
</span><span class="cx">         unlocked_inputs = []
</span><span class="cx">         for test_input in test_inputs:
</span><del>-            if test_input.requires_lock:
</del><ins>+            if test_input.needs_servers:
</ins><span class="cx">                 locked_inputs.append(test_input)
</span><span class="cx">             else:
</span><span class="cx">                 unlocked_inputs.append(test_input)
</span><span class="lines">@@ -506,7 +506,7 @@
</span><span class="cx">             # Note that we use a '.' for the shard name; the name doesn't really
</span><span class="cx">             # matter, and the only other meaningful value would be the filename,
</span><span class="cx">             # which would be really redundant.
</span><del>-            if test_input.requires_lock:
</del><ins>+            if test_input.needs_servers:
</ins><span class="cx">                 locked_shards.append(TestShard('.', [test_input]))
</span><span class="cx">             else:
</span><span class="cx">                 unlocked_shards.append(TestShard('.', [test_input]))
</span><span class="lines">@@ -530,7 +530,7 @@
</span><span class="cx"> 
</span><span class="cx">         for directory, test_inputs in tests_by_dir.iteritems():
</span><span class="cx">             shard = TestShard(directory, test_inputs)
</span><del>-            if test_inputs[0].requires_lock:
</del><ins>+            if test_inputs[0].needs_servers:
</ins><span class="cx">                 locked_shards.append(shard)
</span><span class="cx">             else:
</span><span class="cx">                 unlocked_shards.append(shard)
</span></span></pre></div>
<a id="trunkToolsScriptswebkitpylayout_testscontrollerslayout_test_runner_unittestpy"></a>
<div class="modfile"><h4>Modified: trunk/Tools/Scripts/webkitpy/layout_tests/controllers/layout_test_runner_unittest.py (176813 => 176814)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Tools/Scripts/webkitpy/layout_tests/controllers/layout_test_runner_unittest.py        2014-12-04 21:48:33 UTC (rev 176813)
+++ trunk/Tools/Scripts/webkitpy/layout_tests/controllers/layout_test_runner_unittest.py        2014-12-04 21:49:43 UTC (rev 176814)
</span><span class="lines">@@ -112,10 +112,6 @@
</span><span class="cx">         runner = self._runner()
</span><span class="cx">         self._run_tests(runner, ['http/tests/passes/text.html', 'passes/text.html'])
</span><span class="cx"> 
</span><del>-    def test_perf_locking(self):
-        runner = self._runner()
-        self._run_tests(runner, ['http/tests/passes/text.html', 'perf/foo/test.html'])
-
</del><span class="cx">     def test_interrupt_if_at_failure_limits(self):
</span><span class="cx">         runner = self._runner()
</span><span class="cx">         runner._options.exit_after_n_failures = None
</span><span class="lines">@@ -233,11 +229,10 @@
</span><span class="cx">         &quot;dom/html/level2/html/HTMLAnchorElement03.html&quot;,
</span><span class="cx">         &quot;ietestcenter/Javascript/11.1.5_4-4-c-1.html&quot;,
</span><span class="cx">         &quot;dom/html/level2/html/HTMLAnchorElement06.html&quot;,
</span><del>-        &quot;perf/object-keys.html&quot;,
</del><span class="cx">     ]
</span><span class="cx"> 
</span><span class="cx">     def get_test_input(self, test_file):
</span><del>-        return TestInput(test_file, requires_lock=(test_file.startswith('http') or test_file.startswith('perf')))
</del><ins>+        return TestInput(test_file, needs_servers=(test_file.startswith('http')))
</ins><span class="cx"> 
</span><span class="cx">     def get_shards(self, num_workers, fully_parallel, test_list=None, max_locked_shards=1):
</span><span class="cx">         port = TestPort(MockSystemHost())
</span><span class="lines">@@ -264,8 +259,7 @@
</span><span class="cx">                ['http/tests/security/view-source-no-refresh.html',
</span><span class="cx">                 'http/tests/websocket/tests/unicode.htm',
</span><span class="cx">                 'http/tests/websocket/tests/websocket-protocol-ignored.html',
</span><del>-                'http/tests/xmlhttprequest/supported-xml-content-types.html',
-                'perf/object-keys.html'])])
</del><ins>+                'http/tests/xmlhttprequest/supported-xml-content-types.html'])])
</ins><span class="cx">         self.assert_shards(unlocked,
</span><span class="cx">             [('animations', ['animations/keyframes.html']),
</span><span class="cx">              ('dom/html/level2/html', ['dom/html/level2/html/HTMLAnchorElement03.html',
</span><span class="lines">@@ -279,8 +273,7 @@
</span><span class="cx">             [('.', ['http/tests/websocket/tests/unicode.htm']),
</span><span class="cx">              ('.', ['http/tests/security/view-source-no-refresh.html']),
</span><span class="cx">              ('.', ['http/tests/websocket/tests/websocket-protocol-ignored.html']),
</span><del>-             ('.', ['http/tests/xmlhttprequest/supported-xml-content-types.html']),
-             ('.', ['perf/object-keys.html'])]),
</del><ins>+             ('.', ['http/tests/xmlhttprequest/supported-xml-content-types.html'])]),
</ins><span class="cx">         self.assert_shards(unlocked,
</span><span class="cx">             [('.', ['animations/keyframes.html']),
</span><span class="cx">              ('.', ['fast/css/display-none-inline-style-change-crash.html']),
</span><span class="lines">@@ -295,8 +288,7 @@
</span><span class="cx">               ['http/tests/websocket/tests/unicode.htm',
</span><span class="cx">                'http/tests/security/view-source-no-refresh.html',
</span><span class="cx">                'http/tests/websocket/tests/websocket-protocol-ignored.html',
</span><del>-               'http/tests/xmlhttprequest/supported-xml-content-types.html',
-               'perf/object-keys.html'])])
</del><ins>+               'http/tests/xmlhttprequest/supported-xml-content-types.html'])])
</ins><span class="cx">         self.assert_shards(unlocked,
</span><span class="cx">             [('unlocked_tests',
</span><span class="cx">               ['animations/keyframes.html',
</span><span class="lines">@@ -325,8 +317,7 @@
</span><span class="cx">                'http/tests/websocket/tests/unicode.htm',
</span><span class="cx">                'http/tests/websocket/tests/websocket-protocol-ignored.html']),
</span><span class="cx">              ('locked_shard_2',
</span><del>-              ['http/tests/xmlhttprequest/supported-xml-content-types.html',
-               'perf/object-keys.html'])])
</del><ins>+              ['http/tests/xmlhttprequest/supported-xml-content-types.html'])])
</ins><span class="cx"> 
</span><span class="cx">         locked, unlocked = self.get_shards(num_workers=4, fully_parallel=False)
</span><span class="cx">         self.assert_shards(locked,
</span><span class="lines">@@ -334,5 +325,4 @@
</span><span class="cx">               ['http/tests/security/view-source-no-refresh.html',
</span><span class="cx">                'http/tests/websocket/tests/unicode.htm',
</span><span class="cx">                'http/tests/websocket/tests/websocket-protocol-ignored.html',
</span><del>-               'http/tests/xmlhttprequest/supported-xml-content-types.html',
-               'perf/object-keys.html'])])
</del><ins>+               'http/tests/xmlhttprequest/supported-xml-content-types.html'])])
</ins></span></pre></div>
<a id="trunkToolsScriptswebkitpylayout_testscontrollersmanagerpy"></a>
<div class="modfile"><h4>Modified: trunk/Tools/Scripts/webkitpy/layout_tests/controllers/manager.py (176813 => 176814)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Tools/Scripts/webkitpy/layout_tests/controllers/manager.py        2014-12-04 21:48:33 UTC (rev 176813)
+++ trunk/Tools/Scripts/webkitpy/layout_tests/controllers/manager.py        2014-12-04 21:49:43 UTC (rev 176814)
</span><span class="lines">@@ -78,7 +78,6 @@
</span><span class="cx">         self._expectations = None
</span><span class="cx"> 
</span><span class="cx">         self.HTTP_SUBDIR = 'http' + port.TEST_PATH_SEPARATOR
</span><del>-        self.PERF_SUBDIR = 'perf'
</del><span class="cx">         self.WEBSOCKET_SUBDIR = 'websocket' + port.TEST_PATH_SEPARATOR
</span><span class="cx">         self.LAYOUT_TESTS_DIRECTORY = 'LayoutTests'
</span><span class="cx"> 
</span><span class="lines">@@ -102,9 +101,6 @@
</span><span class="cx">     def _http_tests(self, test_names):
</span><span class="cx">         return set(test for test in test_names if self._is_http_test(test))
</span><span class="cx"> 
</span><del>-    def _is_perf_test(self, test):
-        return self.PERF_SUBDIR == test or (self.PERF_SUBDIR + self._port.TEST_PATH_SEPARATOR) in test
-
</del><span class="cx">     def _prepare_lists(self, paths, test_names):
</span><span class="cx">         tests_to_skip = self._finder.skip_tests(paths, test_names, self._expectations, self._http_tests(test_names))
</span><span class="cx">         tests_to_run = [test for test in test_names if test not in tests_to_skip]
</span><span class="lines">@@ -125,20 +121,13 @@
</span><span class="cx">     def _test_input_for_file(self, test_file):
</span><span class="cx">         return TestInput(test_file,
</span><span class="cx">             self._options.slow_time_out_ms if self._test_is_slow(test_file) else self._options.time_out_ms,
</span><del>-            self._test_requires_lock(test_file))
</del><ins>+            self._is_http_test(test_file))
</ins><span class="cx"> 
</span><del>-    def _test_requires_lock(self, test_file):
-        &quot;&quot;&quot;Return True if the test needs to be locked when
-        running multiple copies of NRWTs. Perf tests are locked
-        because heavy load caused by running other tests in parallel
-        might cause some of them to timeout.&quot;&quot;&quot;
-        return self._is_http_test(test_file) or self._is_perf_test(test_file)
-
</del><span class="cx">     def _test_is_slow(self, test_file):
</span><span class="cx">         return self._expectations.model().has_modifier(test_file, test_expectations.SLOW)
</span><span class="cx"> 
</span><span class="cx">     def needs_servers(self, test_names):
</span><del>-        return any(self._test_requires_lock(test_name) for test_name in test_names) and self._options.http
</del><ins>+        return any(self._is_http_test(test_name) for test_name in test_names) and self._options.http
</ins><span class="cx"> 
</span><span class="cx">     def _set_up_run(self, test_names):
</span><span class="cx">         self._printer.write_update(&quot;Checking build ...&quot;)
</span></span></pre></div>
<a id="trunkToolsScriptswebkitpylayout_testsmodelstest_inputpy"></a>
<div class="modfile"><h4>Modified: trunk/Tools/Scripts/webkitpy/layout_tests/models/test_input.py (176813 => 176814)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Tools/Scripts/webkitpy/layout_tests/models/test_input.py        2014-12-04 21:48:33 UTC (rev 176813)
+++ trunk/Tools/Scripts/webkitpy/layout_tests/models/test_input.py        2014-12-04 21:49:43 UTC (rev 176814)
</span><span class="lines">@@ -31,15 +31,15 @@
</span><span class="cx"> class TestInput(object):
</span><span class="cx">     &quot;&quot;&quot;Groups information about a test for easy passing of data.&quot;&quot;&quot;
</span><span class="cx"> 
</span><del>-    def __init__(self, test_name, timeout=None, requires_lock=None, reference_files=None, should_run_pixel_tests=None):
</del><ins>+    def __init__(self, test_name, timeout=None, needs_servers=None, reference_files=None, should_run_pixel_tests=None):
</ins><span class="cx">         # TestInput objects are normally constructed by the manager and passed
</span><span class="cx">         # to the workers, but these some fields are set lazily in the workers where possible
</span><span class="cx">         # because they require us to look at the filesystem and we want to be able to do that in parallel.
</span><span class="cx">         self.test_name = test_name
</span><span class="cx">         self.timeout = timeout  # in msecs; should rename this for consistency
</span><del>-        self.requires_lock = requires_lock
</del><ins>+        self.needs_servers = needs_servers
</ins><span class="cx">         self.reference_files = reference_files
</span><span class="cx">         self.should_run_pixel_tests = should_run_pixel_tests
</span><span class="cx"> 
</span><span class="cx">     def __repr__(self):
</span><del>-        return &quot;TestInput('%s', timeout=%s, requires_lock=%s, reference_files=%s, should_run_pixel_tests=%s)&quot; % (self.test_name, self.timeout, self.requires_lock, self.reference_files, self.should_run_pixel_tests)
</del><ins>+        return &quot;TestInput('%s', timeout=%s, needs_servers=%s, reference_files=%s, should_run_pixel_tests=%s)&quot; % (self.test_name, self.timeout, self.needs_servers, self.reference_files, self.should_run_pixel_tests)
</ins></span></pre></div>
<a id="trunkToolsScriptswebkitpylayout_testsrun_webkit_tests_integrationtestpy"></a>
<div class="modfile"><h4>Modified: trunk/Tools/Scripts/webkitpy/layout_tests/run_webkit_tests_integrationtest.py (176813 => 176814)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Tools/Scripts/webkitpy/layout_tests/run_webkit_tests_integrationtest.py        2014-12-04 21:48:33 UTC (rev 176813)
+++ trunk/Tools/Scripts/webkitpy/layout_tests/run_webkit_tests_integrationtest.py        2014-12-04 21:49:43 UTC (rev 176814)
</span><span class="lines">@@ -339,9 +339,9 @@
</span><span class="cx">         self.assertEqual(tests_to_run, tests_run)
</span><span class="cx"> 
</span><span class="cx">     def test_no_order_with_directory_entries_in_natural_order(self):
</span><del>-        tests_to_run = ['http/tests/ssl', 'perf/foo', 'http/tests/passes']
</del><ins>+        tests_to_run = ['http/tests/ssl', 'http/tests/passes']
</ins><span class="cx">         tests_run = get_tests_run(['--order=none'] + tests_to_run)
</span><del>-        self.assertEqual(tests_run, ['http/tests/ssl/text.html', 'perf/foo/test.html', 'http/tests/passes/image.html', 'http/tests/passes/text.html'])
</del><ins>+        self.assertEqual(tests_run, ['http/tests/ssl/text.html', 'http/tests/passes/image.html', 'http/tests/passes/text.html'])
</ins><span class="cx"> 
</span><span class="cx">     def test_gc_between_tests(self):
</span><span class="cx">         self.assertTrue(passing_run(['--gc-between-tests']))
</span></span></pre>
</div>
</div>

</body>
</html>