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

Side by Side Diff: LayoutTests/inspector/sources/debugger/async-callstack-events.html

Issue 333333002: DevTools: Instrument DOMWindowEventQueue for async stacks. (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: rebased Created 6 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 | Annotate | Revision Log
« no previous file with comments | « no previous file | LayoutTests/inspector/sources/debugger/async-callstack-events-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
(Empty)
1 <html>
2 <head>
3 <script src="../../../http/tests/inspector/inspector-test.js"></script>
4 <script src="../../../http/tests/inspector/debugger-test.js"></script>
5 <script>
6
7 function testFunction()
8 {
9 for (var name in window) {
10 if (/^doTest[A-Z]/.test(name) && typeof window[name] === "function")
11 window[name]();
12 }
13 }
14
15 function setSelection(start, end)
16 {
17 var node = document.getElementById("content").firstChild;
18 var range = document.createRange();
19 range.setStart(node, start);
20 range.setEnd(node, end);
21 var selection = window.getSelection();
22 selection.removeAllRanges();
23 if (start !== end)
24 selection.addRange(range);
25 }
26
27 function doTestSelectionChange()
28 {
29 setSelection(0, 0);
30 document.addEventListener("selectionchange", onSelectionChange, false);
31 setSelection(0, 4);
32 setSelection(0, 8);
33 setSelection(0, 0);
34 }
35
36 function onSelectionChange()
37 {
38 document.removeEventListener("selectionchange", onSelectionChange, false);
39 debugger;
40 }
41
42 function doTestHashChange()
43 {
44 window.addEventListener("hashchange", onHashChange, false);
45 location.hash = location.hash + "x";
46 }
47
48 function onHashChange()
49 {
50 window.removeEventListener("hashchange", onHashChange, false);
51 debugger;
52 }
53
54 var test = function()
55 {
56 var totalDebuggerStatements = 2;
57 var maxAsyncCallStackDepth = 4;
58 InspectorTest.runAsyncCallStacksTest(totalDebuggerStatements, maxAsyncCallSt ackDepth);
59 }
60
61 </script>
62 </head>
63
64 <body onload="runTest()">
65 <p id="content">
66 Tests asynchronous call stacks for various DOM events.
67 </p>
68 </body>
69 </html>
OLDNEW
« no previous file with comments | « no previous file | LayoutTests/inspector/sources/debugger/async-callstack-events-expected.txt » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698