Title: [92641] trunk/Tools
- Revision
- 92641
- Author
- [email protected]
- Date
- 2011-08-08 15:04:34 -0700 (Mon, 08 Aug 2011)
Log Message
bulk-optimize-baselines should take directories on the command line
https://bugs.webkit.org/show_bug.cgi?id=65879
Reviewed by Dimitri Glazkov.
Passing lists of tests via stdin is a pain. It's easier if the command
takes a list of tests on the command line, like run-webkit-tests.
* Scripts/webkitpy/tool/commands/rebaseline.py:
Modified Paths
Diff
Modified: trunk/Tools/ChangeLog (92640 => 92641)
--- trunk/Tools/ChangeLog 2011-08-08 22:03:10 UTC (rev 92640)
+++ trunk/Tools/ChangeLog 2011-08-08 22:04:34 UTC (rev 92641)
@@ -1,5 +1,17 @@
2011-08-08 Adam Barth <[email protected]>
+ bulk-optimize-baselines should take directories on the command line
+ https://bugs.webkit.org/show_bug.cgi?id=65879
+
+ Reviewed by Dimitri Glazkov.
+
+ Passing lists of tests via stdin is a pain. It's easier if the command
+ takes a list of tests on the command line, like run-webkit-tests.
+
+ * Scripts/webkitpy/tool/commands/rebaseline.py:
+
+2011-08-08 Adam Barth <[email protected]>
+
Deprecate rebaseline-chromium-webkit-tests
https://bugs.webkit.org/show_bug.cgi?id=65873
Modified: trunk/Tools/Scripts/webkitpy/tool/commands/rebaseline.py (92640 => 92641)
--- trunk/Tools/Scripts/webkitpy/tool/commands/rebaseline.py 2011-08-08 22:03:10 UTC (rev 92640)
+++ trunk/Tools/Scripts/webkitpy/tool/commands/rebaseline.py 2011-08-08 22:04:34 UTC (rev 92641)
@@ -30,7 +30,6 @@
import re
import shutil
import urllib
-import fileinput
import webkitpy.common.config.urls as config_urls
from webkitpy.common.checkout.baselineoptimizer import BaselineOptimizer
@@ -42,6 +41,7 @@
from webkitpy.layout_tests.models import test_failures
from webkitpy.layout_tests.models.test_expectations import TestExpectations
from webkitpy.layout_tests.port import factory, builders
+from webkitpy.layout_tests.port import test_files
from webkitpy.tool.grammar import pluralize
from webkitpy.tool.multicommandtool import AbstractDeclarativeCommand
@@ -120,14 +120,17 @@
class BulkOptimizeBaselines(OptimizeBaselines):
name = "bulk-optimize-baselines"
- help_text = """Reshuffles the baselines for tests to use as litte space on disk as possible.
-Please provide the list of tests (separated by new lines) via stdin."""
- argument_names = None
+ help_text = """Reshuffles the baselines for tests to use as litte space on disk as possible."""
+ argument_names = "TEST_NAMES"
+ def _to_test_name(self, file_name):
+ return self._tool.filesystem.relpath(file_name, self._port.layout_tests_dir())
+
def execute(self, options, args, tool):
self._baseline_optimizer = BaselineOptimizer(tool.scm(), tool.filesystem)
- for test_name in fileinput.input(['-']):
- test_name = test_name.strip()
+ self._port = factory.get("chromium-win-win7") # FIXME: This should be selectable.
+
+ for test_name in map(self._to_test_name, test_files.find(self._port, args)):
print "Optimizing %s." % test_name
self._optimize_baseline(test_name)
_______________________________________________
webkit-changes mailing list
[email protected]
http://lists.webkit.org/mailman/listinfo.cgi/webkit-changes