-
-
Notifications
You must be signed in to change notification settings - Fork 3.2k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
LibWeb/URL: Add
strip_trailing_spaces_from_an_opaque_path()
Also remove 2 FIXMEs by including this function.
- Loading branch information
Showing
4 changed files
with
58 additions
and
2 deletions.
There are no files selected for viewing
4 changes: 4 additions & 0 deletions
4
Tests/LibWeb/Text/expected/URL/strip_trailing_spaces_from_opaque_path.txt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
pathname => 'foobar ' | ||
pathname => 'foobar' | ||
pathname => 'baz ' | ||
pathname => 'baz' |
14 changes: 14 additions & 0 deletions
14
Tests/LibWeb/Text/input/URL/strip_trailing_spaces_from_opaque_path.html
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
<script src="../include.js"></script> | ||
<script> | ||
test(() => { | ||
let url = new URL("scheme:foobar ?well=hello"); | ||
println(`pathname => '${url.pathname}'`); | ||
url.search = ""; | ||
println(`pathname => '${url.pathname}'`); | ||
|
||
url = new URL("scheme:baz #friends"); | ||
println(`pathname => '${url.pathname}'`); | ||
url.hash = ""; | ||
println(`pathname => '${url.pathname}'`); | ||
}); | ||
</script> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters