| OLD | NEW |
| 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/debugger-test.js"></script> | 4 <script src="../../../http/tests/inspector/debugger-test.js"></script> |
| 5 <script src="../debugger/resources/framework.js"></script> | 5 <script src="../debugger/resources/framework.js"></script> |
| 6 <script> | 6 <script> |
| 7 | 7 |
| 8 function testFunction() | 8 function testFunction() |
| 9 { | 9 { |
| 10 Framework.throwFrameworkExceptionAndCatch(); | 10 Framework.throwFrameworkExceptionAndCatch(); |
| 11 Framework.throwInNativeAndCatch(); | 11 Framework.throwInNativeAndCatch(); |
| 12 | 12 |
| 13 // All above should be skipped. | 13 // All above should be skipped. |
| 14 debugger; | 14 debugger; |
| 15 } | 15 } |
| 16 | 16 |
| 17 function test() | 17 function test() |
| 18 { | 18 { |
| 19 var frameworkRegexString = "/framework\\.js$"; | 19 var frameworkRegexString = "/framework\\.js$"; |
| 20 InspectorTest.addSniffer(WebInspector.BlackboxManager.prototype, "_patternCh
angeFinishedForTests", step1); |
| 20 WebInspector.settingForTest("skipStackFramesPattern").set(frameworkRegexStri
ng); | 21 WebInspector.settingForTest("skipStackFramesPattern").set(frameworkRegexStri
ng); |
| 21 | 22 |
| 22 InspectorTest.setQuiet(true); | 23 function step1() |
| 23 InspectorTest.startDebuggerTest(step1); | 24 { |
| 25 InspectorTest.setQuiet(true); |
| 26 InspectorTest.startDebuggerTest(step2); |
| 27 } |
| 24 | 28 |
| 25 function step1() | 29 function step2() |
| 26 { | 30 { |
| 27 InspectorTest.DebuggerAgent.setPauseOnExceptions(WebInspector.DebuggerMo
del.PauseOnExceptionsState.PauseOnAllExceptions); | 31 InspectorTest.DebuggerAgent.setPauseOnExceptions(WebInspector.DebuggerMo
del.PauseOnExceptionsState.PauseOnAllExceptions); |
| 28 InspectorTest.runTestFunctionAndWaitUntilPaused(didPause); | 32 InspectorTest.runTestFunctionAndWaitUntilPaused(didPause); |
| 29 } | 33 } |
| 30 | 34 |
| 31 function didPause(callFrames, reason, breakpointIds, asyncStackTrace) | 35 function didPause(callFrames, reason, breakpointIds, asyncStackTrace) |
| 32 { | 36 { |
| 33 InspectorTest.captureStackTrace(callFrames); | 37 InspectorTest.captureStackTrace(callFrames); |
| 34 completeTest(); | 38 completeTest(); |
| 35 } | 39 } |
| 36 | 40 |
| 37 function completeTest() | 41 function completeTest() |
| 38 { | 42 { |
| 39 InspectorTest.DebuggerAgent.setPauseOnExceptions(WebInspector.DebuggerMo
del.PauseOnExceptionsState.DontPauseOnExceptions); | 43 InspectorTest.DebuggerAgent.setPauseOnExceptions(WebInspector.DebuggerMo
del.PauseOnExceptionsState.DontPauseOnExceptions); |
| 40 InspectorTest.completeDebuggerTest(); | 44 InspectorTest.completeDebuggerTest(); |
| 41 } | 45 } |
| 42 } | 46 } |
| 43 | 47 |
| 44 </script> | 48 </script> |
| 45 </head> | 49 </head> |
| 46 | 50 |
| 47 <body onload="runTest()"> | 51 <body onload="runTest()"> |
| 48 <input type='button' onclick='testFunction()' value='Test'/> | 52 <input type='button' onclick='testFunction()' value='Test'/> |
| 49 <p> | 53 <p> |
| 50 Tests that framework black-boxing skips exceptions, including those that happene
d deeper inside V8 native script. | 54 Tests that framework black-boxing skips exceptions, including those that happene
d deeper inside V8 native script. |
| 51 </p> | 55 </p> |
| 52 </body> | 56 </body> |
| 53 </html> | 57 </html> |
| OLD | NEW |