mirror of
https://github.com/denoland/deno.git
synced 2025-08-03 02:22:40 +00:00
Add console.table (#1608)
This commit is contained in:
parent
7c4265159a
commit
f05fd7a1f3
7 changed files with 285 additions and 1 deletions
|
@ -116,7 +116,7 @@ test(function consoleTestStringifyCircular() {
|
|||
assertEqual(
|
||||
stringify(console),
|
||||
// tslint:disable-next-line:max-line-length
|
||||
"Console { printFunc: [Function], log: [Function], debug: [Function], info: [Function], dir: [Function], warn: [Function], error: [Function], assert: [Function], count: [Function], countReset: [Function], time: [Function], timeLog: [Function], timeEnd: [Function], group: [Function], groupCollapsed: [Function], groupEnd: [Function], clear: [Function], indentLevel: 0, collapsedAt: null }"
|
||||
"Console { printFunc: [Function], log: [Function], debug: [Function], info: [Function], dir: [Function], warn: [Function], error: [Function], assert: [Function], count: [Function], countReset: [Function], table: [Function], time: [Function], timeLog: [Function], timeEnd: [Function], group: [Function], groupCollapsed: [Function], groupEnd: [Function], clear: [Function], indentLevel: 0, collapsedAt: null }"
|
||||
);
|
||||
// test inspect is working the same
|
||||
assertEqual(inspect(nestedObj), nestedObjExpected);
|
||||
|
@ -278,6 +278,7 @@ test(function consoleDetachedLog() {
|
|||
const consoleAssert = console.assert;
|
||||
const consoleCount = console.count;
|
||||
const consoleCountReset = console.countReset;
|
||||
const consoleTable = console.table;
|
||||
const consoleTime = console.time;
|
||||
const consoleTimeLog = console.timeLog;
|
||||
const consoleTimeEnd = console.timeEnd;
|
||||
|
@ -293,6 +294,7 @@ test(function consoleDetachedLog() {
|
|||
consoleAssert(true);
|
||||
consoleCount("Hello world");
|
||||
consoleCountReset("Hello world");
|
||||
consoleTable({ test: "Hello world" });
|
||||
consoleTime("Hello world");
|
||||
consoleTimeLog("Hello world");
|
||||
consoleTimeEnd("Hello world");
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue