Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(44)

Issue 2086803002: WIP: blink/run-webkit-tests: Add support for gtest API. (Closed)

Created:
4 years, 6 months ago by mithro
Modified:
4 years, 1 month ago
Reviewers:
Dirk Pranke, qyearsley
CC:
chromium-reviews, blink-reviews, jeffcarp
Base URL:
https://chromium.googlesource.com/chromium/src.git@master
Project:
chromium
Visibility:
Public.

Description

WIP: blink/run-webkit-tests: Add support for gtest API. The gtest library defines a command line / environment variable API for controlling test running (see https://github.com/google/googletest/blob/master/googletest/docs/AdvancedGuide.md#running-test-programs-advanced-options). This API is already supported by many of our other tools, including swarming. To enable run-webkit-tests to be used with these tools, this CL adds this API. BUG=601332, 524758

Patch Set 1 #

Patch Set 2 : Split out random-seeded patch. #

Patch Set 3 : Splitting out the random-order patch #

Total comments: 1
Unified diffs Side-by-side diffs Delta from patch set Stats (+177 lines, -2 lines) Patch
M third_party/WebKit/Tools/Scripts/webkitpy/layout_tests/run_webkit_tests.py View 5 chunks +177 lines, -2 lines 1 comment Download

Messages

Total messages: 7 (3 generated)
mithro
FYI Quinten...
4 years, 6 months ago (2016-06-21 05:00:59 UTC) #2
Dirk Pranke
https://codereview.chromium.org/2086803002/diff/40001/third_party/WebKit/Tools/Scripts/webkitpy/layout_tests/run_webkit_tests.py File third_party/WebKit/Tools/Scripts/webkitpy/layout_tests/run_webkit_tests.py (right): https://codereview.chromium.org/2086803002/diff/40001/third_party/WebKit/Tools/Scripts/webkitpy/layout_tests/run_webkit_tests.py#newcode582 third_party/WebKit/Tools/Scripts/webkitpy/layout_tests/run_webkit_tests.py:582: option_group_definitions.append( I don't necessarily think we should add all ...
4 years, 6 months ago (2016-06-21 22:05:25 UTC) #4
mithro
On 2016/06/21 22:05:25, Dirk Pranke wrote: > https://codereview.chromium.org/2086803002/diff/40001/third_party/WebKit/Tools/Scripts/webkitpy/layout_tests/run_webkit_tests.py > File third_party/WebKit/Tools/Scripts/webkitpy/layout_tests/run_webkit_tests.py > (right): > > ...
4 years, 6 months ago (2016-06-22 13:26:25 UTC) #5
Dirk Pranke
4 years, 5 months ago (2016-06-24 00:06:07 UTC) #6
On 2016/06/22 13:26:25, mithro wrote:
> On 2016/06/21 22:05:25, Dirk Pranke wrote:
> >
>
https://codereview.chromium.org/2086803002/diff/40001/third_party/WebKit/Tool...
> > File
> third_party/WebKit/Tools/Scripts/webkitpy/layout_tests/run_webkit_tests.py
> > (right):
> > 
> >
>
https://codereview.chromium.org/2086803002/diff/40001/third_party/WebKit/Tool...
> >
>
third_party/WebKit/Tools/Scripts/webkitpy/layout_tests/run_webkit_tests.py:582:
> > option_group_definitions.append(
> > I don't necessarily think we should add all of these flags, and I don't know
> > that they're all needed for swarming. Some of them are maybe just different
> > names for existing flags, e.g., gtest_repeat, gtest_shard_index. 
> 
> Looking so far, it seems all the gtest flags have "similar equivalents" in
> run-webkit-tests but some need a bit of massaging.
> 
> I do think we want to implement the complete set of gtest APIs as swarming
based
> functionality is already heading down the path of using that to do things like
> provide single click "rerun failed tests again" and "run test multiple times"
> type functionality. The more similar to other tests the layout tests are, the
> more of this functionality we get for free.

Well, adding code isn't "free" :).

But, yeah, I agree that we should try to make the interfaces identical where
possible,
and that it's good to avoid wrappers where we can.

However, we often already have the wrappers, and you might want to reuse them
instead.

In particular, most of the other python-based test suites (like the telemetry
tests) use a library 
called typ (that I wrote after refactoring stuff out from webkitpy) and there's
more bang for
the buck in sharing code with typ (really, run-webkit-tests should be using typ
directly)
first, before sharing stuff w/ gtest and c++-based.

Though, ideally we should have the same interface for both python- and c++-based
tests.

And, I also find the gtest interface ungainly, and we actually often use our own
flags (via
//base/test/_launcher) anyway, rather than calling gtest directly.

So, my point is that we/you should probably do this in a slightly more visible
way, e.g.,
reach out to phajdan.jr@ and kbr@ and nednguyen@ and others who maintain these
test steps and try to get everyone to agree on an interface. maybe the gtest
interface
is the right thing to do, maybe it isn't.

> I'm definitely like the idea of removing the existing redundant flags, but I
> have a feeling that people are going to complain a lot?

We shouldn't keep arguments around just because we don't want to retrain people.
That leads to unmaintainable code, and we have too much of that in the command
line args for RWT already. And, in these particular examples, I'd be very
surprised
if devs were using any of them at all frequently, so I doubt it'd be a big deal.

To be clear: I'm glad you're working on this stuff, and they seem like good
intentions.
I don't mean to sound too hard here, and apologize if I am.

Powered by Google App Engine
This is Rietveld 408576698