Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(386)

Side by Side Diff: third_party/WebKit/LayoutTests/inspector/console/console-format-table.html

Issue 2918993003: DevTools: allow shallow array values in console.table (Closed)
Patch Set: ac Created 3 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « no previous file | third_party/WebKit/LayoutTests/inspector/console/console-format-table-expected.txt » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 <html> 1 <html>
2 <head> 2 <head>
3 <script src="../../http/tests/inspector/inspector-test.js"></script> 3 <script src="../../http/tests/inspector/inspector-test.js"></script>
4 <script src="../../http/tests/inspector/console-test.js"></script> 4 <script src="../../http/tests/inspector/console-test.js"></script>
5 <script> 5 <script>
6 6
7 function logToConsole() 7 function logToConsole()
8 { 8 {
9 console.table(); 9 console.table();
10 console.table(null); 10 console.table(null);
(...skipping 23 matching lines...) Expand all
34 console.table([[1,2,3], [4,5,6]], "Foo"); 34 console.table([[1,2,3], [4,5,6]], "Foo");
35 35
36 console.log("Array of strings as columns"); 36 console.log("Array of strings as columns");
37 console.table([{a:1, b:2, c:3}, {a:"foo", b:"bar"}], ["a", "b"]); 37 console.table([{a:1, b:2, c:3}, {a:"foo", b:"bar"}], ["a", "b"]);
38 38
39 console.log("Good and bad column names"); 39 console.log("Good and bad column names");
40 console.table([{a:1, b:2, c:3}, {a:"foo"}], ["a", "b", "d"]); 40 console.table([{a:1, b:2, c:3}, {a:"foo"}], ["a", "b", "d"]);
41 41
42 console.log("Missing column name"); 42 console.log("Missing column name");
43 console.table([{a:1, b:2, c:3}, {a:"foo"}], ["d"]); 43 console.table([{a:1, b:2, c:3}, {a:"foo"}], ["d"]);
44
45 console.log("Shallow array");
46 console.table([1, "foo", null]);
47
48 console.log("Shallow array with 'Value' column");
49 console.table([1, {Value: 2}]);
50
51 console.log("Deep and shallow array");
52 console.table([1, "foo", [2]]);
44 } 53 }
45 54
46 function onload() 55 function onload()
47 { 56 {
48 logToConsole(); 57 logToConsole();
49 runTest(); 58 runTest();
50 } 59 }
51 60
52 function test() 61 function test()
53 { 62 {
54 InspectorTest.evaluateInPage("logToConsole()", callback); 63 InspectorTest.evaluateInPage("logToConsole()", callback);
55 64
56 function callback() 65 function callback()
57 { 66 {
58 InspectorTest.dumpConsoleMessages(); 67 InspectorTest.dumpConsoleMessages();
59 InspectorTest.completeTest(); 68 InspectorTest.completeTest();
60 } 69 }
61 } 70 }
62 </script> 71 </script>
63 </head> 72 </head>
64 73
65 <body onload="onload()"> 74 <body onload="onload()">
66 <p> 75 <p>
67 Tests console.table. 76 Tests console.table.
68 </p> 77 </p>
69 </body> 78 </body>
70 </html> 79 </html>
OLDNEW
« no previous file with comments | « no previous file | third_party/WebKit/LayoutTests/inspector/console/console-format-table-expected.txt » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698