Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Web Inspector: Audit: allow audits to be evaluated as a user gesture #1081

Merged
merged 0 commits into from Jun 2, 2022

Conversation

dcrousso
Copy link
Member

@dcrousso dcrousso commented May 27, 2022

7b44a87

Web Inspector: Audit: allow audits to be evaluated as a user gesture
https://bugs.webkit.org/show_bug.cgi?id=200276

Reviewed by Patrick Angle.

This will allow developers to create/run audits that pretend to be a user (e.g. play media, etc.).

* Source/WebCore/inspector/InspectorAuditDOMObject.idl:
* Source/WebCore/inspector/InspectorAuditDOMObject.h:
(WebCore::InspectorAuditDOMObject::create):
* Source/WebCore/inspector/InspectorAuditDOMObject.cpp:
(WebCore::InspectorAuditDOMObject::InspectorAuditDOMObject):
(WebCore::InspectorAuditDOMObject::simulateUserInteraction): Added.

* Source/JavaScriptCore/inspector/protocol/Audit.json:
* Source/WebInspectorUI/UserInterface/Models/AuditTestBase.js:
Increment the current audit version number.

* Source/WebCore/inspector/agents/page/PageAuditAgent.h:
(WebCore::PageAuditAgent::inspectedPage const): Added.
Expose a way for `InspectorAudit*Object` to access the inspected `Page`.

* Source/WebCore/inspector/UserGestureEmulationScope.h: Renamed from Source/WebCore/inspector/agents/page/UserGestureEmulationScope.h.
* Source/WebCore/inspector/UserGestureEmulationScope.cpp: Renamed from Source/WebCore/inspector/agents/page/UserGestureEmulationScope.cpp.
* Source/WebCore/Sources.txt:
* Source/WebCore/WebCore.xcodeproj/project.pbxproj:
Drive-by: Move this file as it's now used by more than just the `Page*Agent` specializations.

* LayoutTests/inspector/audit/run-dom.html:
* LayoutTests/inspector/audit/run-dom-expected.txt:

* LayoutTests/inspector/model/auditTestCase.html:
* LayoutTests/inspector/model/auditTestCase-expected.txt:
* LayoutTests/inspector/model/auditTestGroup.html:
* LayoutTests/inspector/model/auditTestGroup-expected.txt:
Drive-by: Make it so that these tests no longer need to be updated when the audit version changes.

Canonical link: https://commits.webkit.org/251241@main
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@295152 268f45cc-cd09-0410-ab3c-d52691b4dbfc

@dcrousso dcrousso self-assigned this May 27, 2022
@dcrousso dcrousso added Web Inspector Bugs related to the WebKit Web Inspector. WebKit Nightly Build labels May 27, 2022
@webkit-early-warning-system webkit-early-warning-system added the merging-blocked Applied to prevent a change from being merged label May 27, 2022
@dcrousso dcrousso removed merging-blocked Applied to prevent a change from being merged Web Inspector Bugs related to the WebKit Web Inspector. WebKit Nightly Build labels May 27, 2022
@dcrousso dcrousso added Web Inspector Bugs related to the WebKit Web Inspector. WebKit Nightly Build labels May 27, 2022
@webkit-early-warning-system webkit-early-warning-system added the merging-blocked Applied to prevent a change from being merged label May 28, 2022
@dcrousso dcrousso removed merging-blocked Applied to prevent a change from being merged Web Inspector Bugs related to the WebKit Web Inspector. WebKit Nightly Build labels Jun 2, 2022
@dcrousso dcrousso added Web Inspector Bugs related to the WebKit Web Inspector. WebKit Nightly Build labels Jun 2, 2022
@webkit-early-warning-system webkit-early-warning-system added the merging-blocked Applied to prevent a change from being merged label Jun 2, 2022
@dcrousso dcrousso removed merging-blocked Applied to prevent a change from being merged Web Inspector Bugs related to the WebKit Web Inspector. WebKit Nightly Build labels Jun 2, 2022
@dcrousso dcrousso added Web Inspector Bugs related to the WebKit Web Inspector. WebKit Nightly Build merge-queue Applied to send a pull request to merge-queue labels Jun 2, 2022
@webkit-early-warning-system webkit-early-warning-system merged commit 7b44a87 into WebKit:main Jun 2, 2022
@webkit-early-warning-system
Copy link
Collaborator

Committed r295152 (251241@main): https://commits.webkit.org/251241@main

Reviewed commits have been landed. Closing PR #1081 and removing active labels.

@webkit-early-warning-system webkit-early-warning-system removed the merge-queue Applied to send a pull request to merge-queue label Jun 2, 2022
@dcrousso dcrousso deleted the eng/200276 branch June 2, 2022 23:19
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Web Inspector Bugs related to the WebKit Web Inspector.
Projects
None yet
3 participants