Bug 170731 - WebKitTestRunner/DumpRenderTree prevent device from sleeping
Summary: WebKitTestRunner/DumpRenderTree prevent device from sleeping
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: Tools / Tests (show other bugs)
Version: Other
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: Jonathan Bedard
URL:
Keywords: InRadar
Depends on:
Blocks:
 
Reported: 2017-04-11 08:38 PDT by Jonathan Bedard
Modified: 2017-04-28 13:51 PDT (History)
5 users (show)

See Also:


Attachments
Patch (2.20 KB, patch)
2017-04-11 08:43 PDT, Jonathan Bedard
no flags Details | Formatted Diff | Diff
Patch (1.75 KB, patch)
2017-04-11 10:12 PDT, Jonathan Bedard
no flags Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Jonathan Bedard 2017-04-11 08:38:43 PDT
Prevent the device from sleeping while running tests.
Comment 1 Radar WebKit Bug Importer 2017-04-11 08:39:27 PDT
<rdar://problem/31556961>
Comment 2 Jonathan Bedard 2017-04-11 08:43:10 PDT
Created attachment 306820 [details]
Patch
Comment 3 Jonathan Bedard 2017-04-11 08:44:37 PDT
Comment on attachment 306820 [details]
Patch

Removing review flag while I confirm that the toggle is actually needed.
Comment 4 Jonathan Bedard 2017-04-11 10:12:46 PDT
Created attachment 306829 [details]
Patch
Comment 5 Jonathan Bedard 2017-04-11 10:13:55 PDT
We can set this when beginning the test suite.  That seems to be the correct way of doing this.
Comment 6 Alex Christensen 2017-04-12 01:36:15 PDT
Comment on attachment 306829 [details]
Patch

Do we need to unset this?
Comment 7 Jonathan Bedard 2017-04-12 08:11:44 PDT
(In reply to Alex Christensen from comment #6)
> Comment on attachment 306829 [details]
> Patch
> 
> Do we need to unset this?

No, it only persists for the lifetime of the testing app, which we kill when testing is finished.
Comment 8 Alex Christensen 2017-04-28 13:40:21 PDT
Comment on attachment 306829 [details]
Patch

r=me
Maybe we could just put the setting of idleTimerDisabled into setUpIOSLayoutTestCommunication to reduce duplication, and maybe we could rename that function.  Maybe not.
Comment 9 Jonathan Bedard 2017-04-28 13:44:11 PDT
(In reply to Alex Christensen from comment #8)
> Comment on attachment 306829 [details]
> Patch
> 
> r=me
> Maybe we could just put the setting of idleTimerDisabled into
> setUpIOSLayoutTestCommunication to reduce duplication, and maybe we could
> rename that function.  Maybe not.

That function is specifically designed for setting up the communication, it's used for nothing else.  I think duplication is better in this case, if we find we need to do more shared IOS setup between DumpRenderTree and WebKitTestRunnerApp in the future, I will investigate more code sharing.
Comment 10 WebKit Commit Bot 2017-04-28 13:51:00 PDT
Comment on attachment 306829 [details]
Patch

Clearing flags on attachment: 306829

Committed r215942: <http://trac.webkit.org/changeset/215942>
Comment 11 WebKit Commit Bot 2017-04-28 13:51:01 PDT
All reviewed patches have been landed.  Closing bug.