| OLD | NEW |
| (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 function innerTestFunction() | |
| 10 { | |
| 11 timeout1(); | |
| 12 } | |
| 13 setTimeout(innerTestFunction, 0); | |
| 14 } | |
| 15 | |
| 16 function timeout1() | |
| 17 { | |
| 18 debugger; | |
| 19 requestAnimationFrame(animFrame1); | |
| 20 var id = setInterval(innerInterval1, 0); | |
| 21 function innerInterval1() | |
| 22 { | |
| 23 clearInterval(id); | |
| 24 interval1(); | |
| 25 } | |
| 26 } | |
| 27 | |
| 28 function animFrame1() | |
| 29 { | |
| 30 debugger; | |
| 31 setTimeout(timeout2, 0); | |
| 32 requestAnimationFrame(animFrame2); | |
| 33 } | |
| 34 | |
| 35 function interval1() | |
| 36 { | |
| 37 debugger; | |
| 38 } | |
| 39 | |
| 40 function timeout2() | |
| 41 { | |
| 42 debugger; | |
| 43 } | |
| 44 | |
| 45 function animFrame2() | |
| 46 { | |
| 47 debugger; | |
| 48 function longTail0() | |
| 49 { | |
| 50 timeout3(); | |
| 51 } | |
| 52 var funcs = []; | |
| 53 for (var i = 0; i < 20; ++i) | |
| 54 funcs.push("function longTail" + (i + 1) + "() { setTimeout(longTail" +
i + ", 0); };"); | |
| 55 funcs.push("setTimeout(longTail" + i + ", 0);"); | |
| 56 eval(funcs.join("\n")); | |
| 57 } | |
| 58 | |
| 59 function timeout3() | |
| 60 { | |
| 61 debugger; | |
| 62 } | |
| 63 | |
| 64 var test = function() | |
| 65 { | |
| 66 var totalDebuggerStatements = 6; | |
| 67 var maxAsyncCallStackDepth = 4; | |
| 68 InspectorTest.runAsyncCallStacksTest(totalDebuggerStatements, maxAsyncCallSt
ackDepth); | |
| 69 } | |
| 70 | |
| 71 </script> | |
| 72 </head> | |
| 73 | |
| 74 <body onload="runTest()"> | |
| 75 <p> | |
| 76 Tests asynchronous call stacks in debugger. | |
| 77 </p> | |
| 78 | |
| 79 </body> | |
| 80 </html> | |
| OLD | NEW |