← Back to release summary

Permission automation for registerProtocolHandler

Category
Miscellaneous
Type
New or changed feature
Status
No longer pursuing (Chrome No longer pursuing)
Intent stage
Start prototyping

Summary

Provides Automated testing support for the registerProtocolHandler() method, so that we can avoid the user prompt dialog for granting permission for the protocol handler registration. We would need to define a new 'PermissionName' that we can use as part of the 'PermissionDescriptor' argument for the SetPermission command provided by the WebDriver API.

Motivation

Currently there are only manual tests in the WPT repository to cover the registerProtocolHandler functionality. The main challenges to implement automated testing are: * UserActivation: The registerProtocolHandler method requires transient activation to consider the request; otherwise it'll be ignored. * Permission prompt dialog: Although the spec is quite vague on this regard, current implementations (Firefox and Chrome) requires the user to grant permissions for the handler registration. Using the test_driver.set_permission function we could make tests like this way: promise_setup(async () => { await test_driver.set_permission({name: 'protocol-handler'}, 'granted'); await test_driver.bless('handler registration'); // Provides UserActivation register(); });

Standards & signals

Ecosystem

Explainers: https://github.com/Igalia/explainers/blob/main/custom-protocol-handlers/Permission-API/README.md

View on chromestatus.com