Remove more Chromium specific code from webkitpy
authorrniwa@webkit.org <rniwa@webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Sat, 13 Apr 2013 08:02:31 +0000 (08:02 +0000)
committerrniwa@webkit.org <rniwa@webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Sat, 13 Apr 2013 08:02:31 +0000 (08:02 +0000)
https://bugs.webkit.org/show_bug.cgi?id=114552

Reviewed by Philippe Normand.

* Scripts/webkitpy/common/host.py:
(Host.checkout):
* Scripts/webkitpy/layout_tests/layout_package/json_results_generator.py:
(JSONResultsGeneratorBase):
(JSONResultsGeneratorBase.__init__):
(JSONResultsGeneratorBase._is_results_all_of_type):
* Scripts/webkitpy/layout_tests/port/base.py:
(Port):
(Port.expected_filename):
* Scripts/webkitpy/performance_tests/perftestsrunner.py:
(PerfTestsRunner._parse_args):
* Scripts/webkitpy/tool/commands/queues.py:
(PatchProcessingQueue._new_port_name_from_old):
(CommitQueue.did_pass_testing_ews):
* Scripts/webkitpy/tool/commands/rebaseline.py:
(RebaselineTest._results_url):
(Rebaseline._builder_with_name):
* Scripts/webkitpy/tool/mocktool.py:
(MockTool.irc):

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@148352 268f45cc-cd09-0410-ab3c-d52691b4dbfc

Tools/ChangeLog
Tools/Scripts/webkitpy/common/host.py
Tools/Scripts/webkitpy/layout_tests/layout_package/json_results_generator.py
Tools/Scripts/webkitpy/layout_tests/port/base.py
Tools/Scripts/webkitpy/performance_tests/perftestsrunner.py
Tools/Scripts/webkitpy/tool/commands/queues.py
Tools/Scripts/webkitpy/tool/commands/rebaseline.py
Tools/Scripts/webkitpy/tool/mocktool.py

index 59857bc..d91b1a8 100644 (file)
@@ -1,3 +1,30 @@
+2013-04-13  Ryosuke Niwa  <rniwa@webkit.org>
+
+        Remove more Chromium specific code from webkitpy
+        https://bugs.webkit.org/show_bug.cgi?id=114552
+
+        Reviewed by Philippe Normand.
+
+        * Scripts/webkitpy/common/host.py:
+        (Host.checkout):
+        * Scripts/webkitpy/layout_tests/layout_package/json_results_generator.py:
+        (JSONResultsGeneratorBase):
+        (JSONResultsGeneratorBase.__init__):
+        (JSONResultsGeneratorBase._is_results_all_of_type):
+        * Scripts/webkitpy/layout_tests/port/base.py:
+        (Port):
+        (Port.expected_filename):
+        * Scripts/webkitpy/performance_tests/perftestsrunner.py:
+        (PerfTestsRunner._parse_args):
+        * Scripts/webkitpy/tool/commands/queues.py:
+        (PatchProcessingQueue._new_port_name_from_old):
+        (CommitQueue.did_pass_testing_ews):
+        * Scripts/webkitpy/tool/commands/rebaseline.py:
+        (RebaselineTest._results_url):
+        (Rebaseline._builder_with_name):
+        * Scripts/webkitpy/tool/mocktool.py:
+        (MockTool.irc):
+
 2013-04-13  Zan Dobersek  <zdobersek@igalia.com>
 
         Fix flakiness dashboard unit test failures
index 73af0b3..c7ba15e 100644 (file)
@@ -89,11 +89,6 @@ class Host(SystemHost):
     def checkout(self):
         return self._checkout
 
-    def buildbot_for_builder_name(self, name):
-        if self.port_factory.get_from_builder_name(name).is_chromium():
-            return self.chromium_buildbot()
-        return self.buildbot
-
     @memoized
     def watch_list(self):
         return WatchListLoader(self.filesystem).load()
index 4729733..252572b 100644 (file)
@@ -188,16 +188,12 @@ class JSONResultsGeneratorBase(object):
 
     URL_FOR_TEST_LIST_JSON = "http://%s/testfile?builder=%s&name=%s&testlistjson=1&testtype=%s&master=%s"
 
-    # FIXME: Remove generate_incremental_results once the reference to it in
-    # http://src.chromium.org/viewvc/chrome/trunk/tools/build/scripts/slave/gtest_slave_utils.py
-    # has been removed.
     def __init__(self, port, builder_name, build_name, build_number,
         results_file_base_path, builder_base_url,
         test_results_map, svn_repositories=None,
         test_results_server=None,
         test_type="",
-        master_name="",
-        generate_incremental_results=None):
+        master_name=""):
         """Modifies the results.json file. Grabs it off the archive directory
         if it is not found locally.
 
@@ -645,8 +641,3 @@ class JSONResultsGeneratorBase(object):
         """Returns whether all the results are of the given type
         (e.g. all passes)."""
         return len(results) == 1 and results[0][1] == type
-
-
-# Left here not to break anything.
-class JSONResultsGenerator(JSONResultsGeneratorBase):
-    pass
index c26073a..9ddbded 100644 (file)
@@ -73,8 +73,7 @@ class Port(object):
     """Abstract class for Port-specific hooks for the layout_test package."""
 
     # Subclasses override this. This should indicate the basic implementation
-    # part of the port name, e.g., 'chromium-mac', 'win', 'gtk'; there is probably (?)
-    # one unique value per class.
+    # part of the port name, e.g., 'win', 'gtk'; there is probably (?) one unique value per class.
 
     # FIXME: We should probably rename this to something like 'implementation_name'.
     port_name = None
@@ -485,8 +484,7 @@ class Port(object):
         suffix: file suffix of the expected results, including dot; e.g. '.txt'
             or '.png'.  This should not be None, but may be an empty string.
         platform: the most-specific directory name to use to build the
-            search list of directories, e.g., 'chromium-win', or
-            'chromium-cg-mac-leopard' (we follow the WebKit format)
+            search list of directories; e.g. 'mountainlion-wk2'
         return_default: if True, returns the path to the generic expectation if nothing
             else is found; if False, returns None.
 
index b3e22e7..1877d02 100644 (file)
@@ -84,10 +84,6 @@ class PerfTestsRunner(object):
                 help='Set the configuration to Release'),
             optparse.make_option("--platform",
                 help="Specify port/platform being tested (i.e. chromium-mac)"),
-            optparse.make_option("--chromium",
-                action="store_const", const='chromium', dest='platform', help='Alias for --platform=chromium'),
-            optparse.make_option("--chromium-android",
-                action="store_const", const='chromium-android', dest='platform', help='Alias for --platform=chromium-android'),
             optparse.make_option("--builder-name",
                 help=("The name of the builder shown on the waterfall running this script e.g. google-mac-2.")),
             optparse.make_option("--build-number",
index 274e0ea..f68b51a 100644 (file)
@@ -261,9 +261,6 @@ class PatchProcessingQueue(AbstractPatchQueue):
 
     # FIXME: This is a hack to map between the old port names and the new port names.
     def _new_port_name_from_old(self, port_name, platform):
-        # The new port system has no concept of xvfb yet.
-        if port_name == 'chromium-xvfb':
-            return 'chromium'
         # ApplePort.determine_full_port_name asserts if the name doesn't include version.
         if port_name == 'mac':
             return 'mac-' + platform.os_version
@@ -381,9 +378,9 @@ class CommitQueue(PatchProcessingQueue, StepSequenceErrorHandler, CommitQueueTas
         reporter.report_flaky_tests(patch, flaky_test_results, results_archive)
 
     def did_pass_testing_ews(self, patch):
-        # Currently, chromium-ews is the only testing EWS. Once there are more,
-        # should make sure they all pass.
-        status = self._tool.status_server.patch_status("chromium-ews", patch.id())
+        # Only Mac and Mac WK2 run tests
+        # FIXME: We shouldn't have to hard-code it here.
+        status = self._tool.status_server.patch_status("mac", patch.id())
         return status == self._pass_status
 
     # StepSequenceErrorHandler methods
index e428066..e8ae8f3 100644 (file)
@@ -88,7 +88,7 @@ class RebaselineTest(AbstractRebaseliningCommand):
         self._scm_changes = {'add': []}
 
     def _results_url(self, builder_name):
-        return self._tool.buildbot_for_builder_name(builder_name).builder_with_name(builder_name).latest_layout_test_results_url()
+        return self._tool.buildbot.builder_with_name(builder_name).latest_layout_test_results_url()
 
     def _baseline_directory(self, builder_name):
         port = self._tool.port_factory.get_from_builder_name(builder_name)
@@ -465,7 +465,7 @@ class Rebaseline(AbstractParallelRebaselineCommand):
         return [self._builder_with_name(name) for name in chosen_names]
 
     def _builder_with_name(self, name):
-        return self._tool.buildbot_for_builder_name(name).builder_with_name(name)
+        return self._tool.buildbot.builder_with_name(name)
 
     def _tests_to_update(self, builder):
         failing_tests = builder.latest_layout_test_results().tests_matching_failure_types([test_failures.FailureTextMismatch])
index 8afaea9..175d1b8 100644 (file)
@@ -83,6 +83,3 @@ class MockTool(MockHost):
 
     def irc(self):
         return self._irc
-
-    def buildbot_for_builder_name(self, name):
-        return MockBuildBot()