Bug 112147 - [Qt] Port TestRunner::findString to shared interface
Summary: [Qt] Port TestRunner::findString to shared interface
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: New Bugs (show other bugs)
Version: 528+ (Nightly build)
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: Simon Hausmann
URL:
Keywords:
Depends on: 112144
Blocks: 109677
  Show dependency treegraph
 
Reported: 2013-03-12 06:48 PDT by Simon Hausmann
Modified: 2013-03-13 08:26 PDT (History)
1 user (show)

See Also:


Attachments
Patch (18.50 KB, patch)
2013-03-12 06:50 PDT, Simon Hausmann
no flags Details | Formatted Diff | Diff
Patch (13.92 KB, patch)
2013-03-12 06:51 PDT, Simon Hausmann
no flags Details | Formatted Diff | Diff
Patch (18.50 KB, patch)
2013-03-12 08:08 PDT, Simon Hausmann
no flags Details | Formatted Diff | Diff
Patch (13.92 KB, patch)
2013-03-13 05:53 PDT, Simon Hausmann
no flags Details | Formatted Diff | Diff
Patch (22.84 KB, patch)
2013-03-13 07:06 PDT, Simon Hausmann
jturcotte: review+
Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Simon Hausmann 2013-03-12 06:48:16 PDT
[Qt] Port TestRunner::findString to shared interface
Comment 1 Simon Hausmann 2013-03-12 06:50:07 PDT
Created attachment 192727 [details]
Patch
Comment 2 Simon Hausmann 2013-03-12 06:51:28 PDT
Created attachment 192728 [details]
Patch
Comment 3 Simon Hausmann 2013-03-12 08:08:02 PDT
Created attachment 192738 [details]
Patch
Comment 4 Benjamin Poulain 2013-03-13 00:37:24 PDT
Comment on attachment 192738 [details]
Patch

Wrong patch :(
Comment 5 Simon Hausmann 2013-03-13 05:53:31 PDT
Created attachment 192907 [details]
Patch
Comment 6 Jocelyn Turcotte 2013-03-13 06:23:00 PDT
Comment on attachment 192907 [details]
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=192907&action=review

> Tools/DumpRenderTree/qt/DumpRenderTreeQt.cpp:388
> +static DumpRenderTree *s_instance;

The compiler should do it but it might be worth explicitely initializing it to 0.

> Tools/DumpRenderTree/qt/TestRunnerQt.cpp:748
> +bool TestRunner::findString(JSContextRef context, JSStringRef string, JSObjectRef optionsArray)

EFL, GTK, chromium and BlackBerry all seem to do the FindOptions matching in TestRunner instead of DumpRenderTreeSupport.
It might be worth doing the same while we're there.

> Tools/DumpRenderTree/qt/TestRunnerQt.cpp:750
> +    DumpRenderTree* drt = DumpRenderTree::instance();

It seems like this could be moved right before or into the final return.

> Tools/DumpRenderTree/qt/TestRunnerQt.cpp:766
> +

Superfluous
Comment 7 Simon Hausmann 2013-03-13 07:01:57 PDT
Comment on attachment 192907 [details]
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=192907&action=review

>> Tools/DumpRenderTree/qt/DumpRenderTreeQt.cpp:388
>> +static DumpRenderTree *s_instance;
> 
> The compiler should do it but it might be worth explicitely initializing it to 0.

Done.

>> Tools/DumpRenderTree/qt/TestRunnerQt.cpp:748
>> +bool TestRunner::findString(JSContextRef context, JSStringRef string, JSObjectRef optionsArray)
> 
> EFL, GTK, chromium and BlackBerry all seem to do the FindOptions matching in TestRunner instead of DumpRenderTreeSupport.
> It might be worth doing the same while we're there.

Okay.

>> Tools/DumpRenderTree/qt/TestRunnerQt.cpp:750
>> +    DumpRenderTree* drt = DumpRenderTree::instance();
> 
> It seems like this could be moved right before or into the final return.

Good idea! done.

>> Tools/DumpRenderTree/qt/TestRunnerQt.cpp:766
>> +
> 
> Superfluous

Oops :)
Comment 8 Simon Hausmann 2013-03-13 07:06:21 PDT
Created attachment 192917 [details]
Patch
Comment 9 Jocelyn Turcotte 2013-03-13 08:23:04 PDT
Comment on attachment 192917 [details]
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=192917&action=review

LGTM after all :)

> Tools/DumpRenderTree/qt/TestRunnerQt.cpp:782
> +

This can be removed, I didn't see it earlier
Comment 10 Simon Hausmann 2013-03-13 08:26:48 PDT
Committed r145719: <http://trac.webkit.org/changeset/145719>