Changeset 107374 in webkit


Ignore:
Timestamp:
Feb 10, 2012 12:05:53 AM (12 years ago)
Author:
Philippe Normand
Message:

[GTK] EWS command-line option to run the tests
https://bugs.webkit.org/show_bug.cgi?id=78211

Reviewed by Adam Barth.

New --run-tests option (defaults to False) for the EWS commands.

  • Scripts/webkitpy/tool/commands/earlywarningsystem.py:

(AbstractEarlyWarningSystem):
(AbstractEarlyWarningSystem.init):
(AbstractEarlyWarningSystem.review_patch):
(ChromiumLinuxEWS):

  • Scripts/webkitpy/tool/commands/earlywarningsystem_unittest.py:

(EarlyWarningSytemTest._test_builder_ews):

Location:
trunk/Tools
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • trunk/Tools/ChangeLog

    r107361 r107374  
     12012-02-09  Philippe Normand  <pnormand@igalia.com>
     2
     3        [GTK] EWS command-line option to run the tests
     4        https://bugs.webkit.org/show_bug.cgi?id=78211
     5
     6        Reviewed by Adam Barth.
     7
     8        New --run-tests option (defaults to False) for the EWS commands.
     9
     10        * Scripts/webkitpy/tool/commands/earlywarningsystem.py:
     11        (AbstractEarlyWarningSystem):
     12        (AbstractEarlyWarningSystem.__init__):
     13        (AbstractEarlyWarningSystem.review_patch):
     14        (ChromiumLinuxEWS):
     15        * Scripts/webkitpy/tool/commands/earlywarningsystem_unittest.py:
     16        (EarlyWarningSytemTest._test_builder_ews):
     17
    1182012-02-09  Eric Seidel  <eric@webkit.org>
    219
  • trunk/Tools/Scripts/webkitpy/tool/commands/earlywarningsystem.py

    r107297 r107374  
    2727# OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
    2828
     29from optparse import make_option
     30
    2931from webkitpy.common.config.committers import CommitterList
    3032from webkitpy.common.config.ports import DeprecatedPort
     
    4042class AbstractEarlyWarningSystem(AbstractReviewQueue, EarlyWarningSystemTaskDelegate):
    4143    _build_style = "release"
    42     # FIXME: Switch _run_tests from opt-in to opt-out once more bots are ready to run tests.
    43     _run_tests = False
     44    # FIXME: Switch _default_run_tests from opt-in to opt-out once more bots are ready to run tests.
     45    _default_run_tests = False
    4446
    4547    def __init__(self):
    46         AbstractReviewQueue.__init__(self)
     48        options = [make_option("--run-tests", action="store_true", dest="run_tests", default=self._default_run_tests, help="Run the Layout tests for each patch")]
     49        AbstractReviewQueue.__init__(self, options=options)
    4750        self.port = DeprecatedPort.port(self.port_name)
    4851
     
    7477
    7578    def review_patch(self, patch):
    76         task = EarlyWarningSystemTask(self, patch, self._run_tests)
     79        task = EarlyWarningSystemTask(self, patch, self._options.run_tests)
    7780        if not task.validate():
    7881            self._did_error(patch, "%s did not process patch." % self.name)
     
    180183    name = "chromium-ews"
    181184    port_name = "chromium-xvfb"
    182     _run_tests = True
     185    _default_run_tests = True
    183186
    184187
  • trunk/Tools/Scripts/webkitpy/tool/commands/earlywarningsystem_unittest.py

    r107302 r107374  
    6868    def _test_builder_ews(self, ews):
    6969        ews.bind_to_tool(MockTool())
    70         self.assert_queue_outputs(ews, expected_stderr=self._default_expected_stderr(ews))
     70        options = Mock()
     71        options.port = None
     72        options.run_tests = ews._default_run_tests
     73        self.assert_queue_outputs(ews, expected_stderr=self._default_expected_stderr(ews), options=options)
    7174
    7275    def _test_testing_ews(self, ews):
Note: See TracChangeset for help on using the changeset viewer.