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

Side by Side Diff: LayoutTests/inspector/console/console-command-copy.html

Issue 102433002: [DevTools] Improved console.copy command to handle JSON.stringifyable objects. (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 7 years 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 | Annotate | Revision Log
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 test() 7 function test()
8 { 8 {
9 var pendingCount = 5;
10 InspectorFrontendHost.copyText = copyText;
11
9 InspectorTest.evaluateInConsole("copy('qwerty')"); 12 InspectorTest.evaluateInConsole("copy('qwerty')");
10 InspectorFrontendHost.copyText = copyText; 13 InspectorTest.evaluateInConsole("copy(document.querySelector('p'))");
11 14 InspectorTest.evaluateInConsole("copy({foo:'bar'})");
15 // Check cyclic references in objects
16 InspectorTest.evaluateInConsole("var a = {}; a.b = a; copy(a)");
17 InspectorTest.evaluateInConsole("copy(document.all)");
18
12 function copyText(text) { 19 function copyText(text) {
13 InspectorTest.addResult("InspectorFrontendHost.copyText: " + text); 20 InspectorTest.addResult("InspectorFrontendHost.copyText: " + text);
14 InspectorTest.completeTest(); 21 if (--pendingCount === 0)
22 InspectorTest.completeTest();
15 } 23 }
16 } 24 }
17 25
18 </script> 26 </script>
19 </head> 27 </head>
20 28
21 <body onload="runTest()"> 29 <body onload="runTest()">
22 <p> 30 <p>
23 Tests that console's copy command is copying into front-end buffer. 31 Tests that console's copy command is copying into front-end buffer.
24 </p> 32 </p>
25 33
26 </body> 34 </body>
27 </html> 35 </html>
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698