Skip to content

Commit

Permalink
test: validate host with commas on url.parse
Browse files Browse the repository at this point in the history
PR-URL: nodejs#48878
Refs: nodejs#48873
Refs: nodejs#48855
Refs: nodejs#48850
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com>
Reviewed-By: Antoine du Hamel <duhamelantoine1995@gmail.com>
  • Loading branch information
anonrig authored and Ceres6 committed Jul 27, 2023
1 parent d19df78 commit 932d92e
Showing 1 changed file with 16 additions and 0 deletions.
16 changes: 16 additions & 0 deletions test/parallel/test-url-parse-format.js
Original file line number Diff line number Diff line change
Expand Up @@ -1007,6 +1007,22 @@ const parseTests = {
path: '/',
href: 'https://evil.com$.example.com/'
},

// Validate the output of hostname with commas.
'x://0.0,1.1/': {
protocol: 'x:',
slashes: true,
auth: null,
host: '0.0,1.1',
port: null,
hostname: '0.0,1.1',
hash: null,
search: null,
query: null,
pathname: '/',
path: '/',
href: 'x://0.0,1.1/'
}
};

for (const u in parseTests) {
Expand Down

0 comments on commit 932d92e

Please sign in to comment.