Bug 48095 - new-run-webkit-tests: need a better way to handle port-specific options and default values
Summary: new-run-webkit-tests: need a better way to handle port-specific options and d...
Status: RESOLVED WONTFIX
Alias: None
Product: WebKit
Classification: Unclassified
Component: Tools / Tests (show other bugs)
Version: 528+ (Nightly build)
Hardware: PC OS X 10.5
: P2 Normal
Assignee: Nobody
URL:
Keywords:
Depends on:
Blocks: 50043
  Show dependency treegraph
 
Reported: 2010-10-21 15:04 PDT by Dirk Pranke
Modified: 2011-06-24 14:50 PDT (History)
5 users (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Dirk Pranke 2010-10-21 15:04:45 PDT
Currently, we specify all of the options, for all ports, to new-run-webkit-tests in run_webkit_tests.py. This is (a) a layering problem, (b) makes us see every option supported by any port, and (c) gives us no easy way to specify port-specific default values.

I think the only way to really solve this is to parse the options in two passes, the first to figure out which port to use, and then grab the port-specific options and defaults and reparse. (Note that there may be port-specific defaults for generic options). 

In addition, we need to be careful to ensure that when ports do define options, they all define the option the same way, to avoid confusion.
Comment 1 Dirk Pranke 2011-06-24 14:50:54 PDT
The current code has the virtue that (nearly all of) the command line options are declared in one place (in run_webkit_tests.py). 

I've come to believe that this is actually easier for people to modify and maintain than it would be if we scattered all of the options among multiple modules. Of course, the downsides are the layering issues and the ability to set port-specific defaults.

I guess what I'm saying is that it's not obvious to me what the "better" way would be. I'm clearing ownership and marking this as WONTFIX for now. Someone can reopen and start working on it if they have any better ideas than I do.