Skip to content

Commit

Permalink
test: add test for URLSearchParams inspection
Browse files Browse the repository at this point in the history
The member methods of URLSearchParams should split across multiple
lines with `util.inspect` depending on an option `breakLength`.

PR-URL: nodejs#11428
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Timothy Gu <timothygu99@gmail.com>
Reviewed-By: Joyee Cheung <joyeec9h3@gmail.com>
Reviewed-By: Michaël Zasso <targos@protonmail.com>
  • Loading branch information
watilde authored and italoacasas committed Feb 25, 2017
1 parent ae9b891 commit 8e455a9
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions test/parallel/test-whatwg-url-searchparams-inspect.js
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,8 @@ assert.strictEqual(util.inspect(sp.keys()),
"URLSearchParamsIterator { 'a', 'b', 'b' }");
assert.strictEqual(util.inspect(sp.values()),
"URLSearchParamsIterator { 'a', 'b', 'c' }");
assert.strictEqual(util.inspect(sp.keys(), {breakLength: 1}),
"URLSearchParamsIterator {\n 'a',\n 'b',\n 'b' }");

const iterator = sp.entries();
assert.strictEqual(util.inspect(iterator),
Expand Down

0 comments on commit 8e455a9

Please sign in to comment.