fix(op_crates/web/url): apply backslash replacement to the pathname setter (#7937)

This commit is contained in:
Nayeem Rahman 2020-10-13 16:16:10 +01:00 committed by GitHub
parent bbf7b2ee72
commit d0c2714c03
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 6 additions and 2 deletions

View file

@ -192,6 +192,8 @@ unitTest(function urlModifyPathname(): void {
// deno-lint-ignore no-self-assign
url.pathname = url.pathname;
assertEquals(url.pathname, "/baz%23qat%20qux");
url.pathname = "\\a\\b\\c";
assertEquals(url.pathname, "/a/b/c");
});
unitTest(function urlModifyHash(): void {