Skip to content

Commit

Permalink
URLPattern: More WPT tests with '.' and '..'.
Browse files Browse the repository at this point in the history
This CL adds some more test cases for issues discussed in:

whatwg/urlpattern#156

Change-Id: I885a61aa6be3d416babfa7c23b19465d0c63d07a
  • Loading branch information
wanderview authored and chromium-wpt-export-bot committed Jan 18, 2022
1 parent fd132ae commit 1ceb921
Showing 1 changed file with 28 additions and 0 deletions.
28 changes: 28 additions & 0 deletions urlpattern/resources/urlpatterntestdata.json
Original file line number Diff line number Diff line change
Expand Up @@ -2679,5 +2679,33 @@
"expected_match": {
"pathname": { "input": "/bar..", "groups": { "foo": "bar" } }
}
},
{
"pattern": [{ "pathname": "./foo" }],
"inputs": [{ "pathname": "./foo" }],
"expected_match": {
"pathname": { "input": "./foo", "groups": {}}
}
},
{
"pattern": [{ "pathname": "../foo" }],
"inputs": [{ "pathname": "../foo" }],
"expected_match": {
"pathname": { "input": "../foo", "groups": {}}
}
},
{
"pattern": [{ "pathname": ":foo./" }],
"inputs": [{ "pathname": "bar./" }],
"expected_match": {
"pathname": { "input": "bar./", "groups": { "foo": "bar" }}
}
},
{
"pattern": [{ "pathname": ":foo../" }],
"inputs": [{ "pathname": "bar../" }],
"expected_match": {
"pathname": { "input": "bar../", "groups": { "foo": "bar" }}
}
}
]

0 comments on commit 1ceb921

Please sign in to comment.