Remove unused functionality from gardeningserver
authorabarth@webkit.org <abarth@webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Mon, 1 Aug 2011 20:39:31 +0000 (20:39 +0000)
committerabarth@webkit.org <abarth@webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Mon, 1 Aug 2011 20:39:31 +0000 (20:39 +0000)
https://bugs.webkit.org/show_bug.cgi?id=65479

Reviewed by Dimitri Glazkov.

We now handle these operations directly from the front-end.  That means
they work even without the gardening server running!

Also, add some missing files to the list of static files.

* Scripts/webkitpy/tool/servers/gardeningserver.py:
* Scripts/webkitpy/tool/servers/gardeningserver_unittest.py:

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

Tools/ChangeLog
Tools/Scripts/webkitpy/tool/servers/gardeningserver.py
Tools/Scripts/webkitpy/tool/servers/gardeningserver_unittest.py

index 91678cb..05df07d 100644 (file)
@@ -1,3 +1,18 @@
+2011-08-01  Adam Barth  <abarth@webkit.org>
+
+        Remove unused functionality from gardeningserver
+        https://bugs.webkit.org/show_bug.cgi?id=65479
+
+        Reviewed by Dimitri Glazkov.
+
+        We now handle these operations directly from the front-end.  That means
+        they work even without the gardening server running!
+
+        Also, add some missing files to the list of static files.
+
+        * Scripts/webkitpy/tool/servers/gardeningserver.py:
+        * Scripts/webkitpy/tool/servers/gardeningserver_unittest.py:
+
 2011-08-01  Dimitri Glazkov  <dglazkov@chromium.org>
 
         Introduce SpecifierSorter, a thing that knows how specifiers should be ordered.
index 8785ea3..6a8559f 100644 (file)
@@ -38,6 +38,8 @@ class GardeningHTTPServer(BaseHTTPServer.HTTPServer):
 class GardeningHTTPRequestHandler(ReflectionHandler):
     STATIC_FILE_NAMES = frozenset([
         "base.js",
+        "Bugzilla.js",
+        "builders.js",
         "checkout.js",
         "config.js",
         "favicon-green.png",
@@ -66,23 +68,6 @@ class GardeningHTTPRequestHandler(ReflectionHandler):
     def _run_webkit_patch(self, args):
         return self.server.tool.executive.run_command([self.server.tool.path()] + args, cwd=self.server.tool.scm().checkout_root)
 
-    def changelog(self):
-        revision = self.query['revision'][0]
-        head_revision = self.server.tool.scm().head_svn_revision()
-        if revision > head_revision:
-            # Updating the working copy could conflict with any rebaselines we have in progress.
-            update_webkit_command = self.server.tool.port().update_webkit_command()
-            self.server.tool.executive.run_and_throw_if_fail(update_webkit_command, quiet=True, cwd=self.server.tool.scm().checkout_root)
-        commit_info = self.server.tool.checkout().commit_info_for_revision(revision)
-        if not commit_info:
-            self.send_error(404, "File not found")
-        else:
-            self._serve_json(commit_info.to_json())
-
-    def buildbot(self):
-        builder_statuses = self.server.tool.chromium_buildbot().builder_statuses()
-        self._serve_json(builder_statuses)
-
     def rollout(self):
         revision = self.query['revision'][0]
         reason = self.query['reason'][0]
index 0c96757..cc7b357 100644 (file)
@@ -69,18 +69,6 @@ class GardeningServerTest(unittest.TestCase):
         handler.path = path
         OutputCapture().assert_outputs(self, handler.do_POST, expected_stderr=expected_stderr, expected_stdout=expected_stdout)
 
-    def test_changelog(self):
-        expected_stderr = "MOCK run_and_throw_if_fail: ['mock-update-webkit'], cwd=/mock-checkout\n"
-        expected_stdout = """== Begin JSON Response ==
-{"bug_id": 42, "author_email": "abarth@webkit.org", "reviewer_text": "Darin Adler", "author_name": "Adam Barth", "changed_files": ["path/to/file", "another/file"]}
-== End JSON Response ==
-"""
-        self._post_to_path("/changelog?revision=2314", expected_stderr=expected_stderr, expected_stdout=expected_stdout)
-
-    def test_buildbot(self):
-        expected_stdout = '== Begin JSON Response ==\n[{"is_green": true, "name": "Builder1", "activity": "building"}, {"is_green": true, "name": "Builder2", "activity": "idle"}]\n== End JSON Response ==\n'
-        self._post_to_path("/buildbot", expected_stdout=expected_stdout, expected_stderr='')
-
     def test_rollout(self):
         expected_stderr = "MOCK run_command: ['echo', 'rollout', '--force-clean', '--non-interactive', '2314', 'MOCK rollout reason'], cwd=/mock-checkout\n"
         expected_stdout = "== Begin Response ==\nsuccess\n== End Response ==\n"