GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — test: check inspect array with empty string key · nodejs/node@cd238e2

File tree

Expand file treeCollapse file tree
Open diff view settings
Filter options
  • test/parallel
    • test-util-inspect.js
Expand file treeCollapse file tree
Open diff view settings
Collapse file

‎test/parallel/test-util-inspect.js‎

Copy file name to clipboardExpand all lines: test/parallel/test-util-inspect.js
+6Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -959,6 +959,12 @@ if (typeof Symbol !== 'undefined') {
959959
assert.strictEqual(util.inspect(x), '{}');
960960
}
961961

962+
{
963+
const x = [];
964+
x[''] = 1;
965+
assert.strictEqual(util.inspect(x), '[ \'\': 1 ]');
966+
}
967+
962968
// The following maxArrayLength tests were introduced after v6.0.0 was released.
963969
// Do not backport to v5/v4 unless all of
964970
// https://github.com/nodejs/node/pull/6334 is backported.

0 commit comments

Comments
0 (0)
You are visitor 01402503 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.