Skip to content

Add registerProtocolHandler tests for FTP.#32739

Open
asankah wants to merge 2 commits into
web-platform-tests:masterfrom
asankah:ftp-registerprotocolhandler
Open

Add registerProtocolHandler tests for FTP.#32739
asankah wants to merge 2 commits into
web-platform-tests:masterfrom
asankah:ftp-registerprotocolhandler

Conversation

@asankah
Copy link
Copy Markdown
Contributor

@asankah asankah commented Feb 8, 2022

registerProtocolHandler allows registering ftp, ftps, and sftp
protocols as of whatwg/html#6584.

This change adds tests to ensure that registerProtocolHandler allows
registering those protocols and to ensure that embedded credentials are
removed prior to invoking the custom protocol handler.

`registerProtocolHandler` allows registering `ftp`, `ftps`, and `sftp`
protocols as of whatwg/html#6584.

This change adds tests to ensure that `registerProtocolHandler` allows
registering those protocols and to ensure that embedded credentials are
removed prior to invoking the custom protocol handler.
@asankah
Copy link
Copy Markdown
Contributor Author

asankah commented Feb 8, 2022

Note that the registerProtocolHandler manual tests have pre-existing issues that aren't addressed in this change. In particular the list of codepoints that are used to construct the URL being passed into the custom protocol handler aren't all URL safe, but the test assumes that they are passed in unescaped. We should probably address that separately.

@asankah
Copy link
Copy Markdown
Contributor Author

asankah commented Feb 8, 2022

cc @domenic @annevk

@asankah
Copy link
Copy Markdown
Contributor Author

asankah commented Feb 16, 2022

Ping?

Copy link
Copy Markdown
Member

@annevk annevk left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This looks good to me. I assume you checked that it doesn't change the results in the existing tests?

You might also want to add a test for ftps since I suspect that will be failed by Chrome/Firefox (mainly due to a faulty implementation of the URL parser).

…ject/resources/handler-tools.js

Co-authored-by: Anne van Kesteren <annevk@annevk.nl>
@foolip
Copy link
Copy Markdown
Member

foolip commented Mar 18, 2022

@asankah there are conflicts now that aren't trivial enough for me to resolve, can you take a look? And do you want to add the ftps variants that @annevk suggested?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants