|
|
| 21 | 21 | f4();
|
|---|
| 22 | 22 | </script>
|
|---|
| 23 | 23 |
|
|---|
| 24 | | <script src="../../../http/tests/inspector/inspector-test.js"></script>
|
|---|
| 25 | | <script src="../../../http/tests/inspector/debugger-test.js"></script>
|
|---|
| 26 | |
|
|---|
| 27 | | <script>
|
|---|
| 28 | |
|
|---|
| 29 | | var test = function()
|
|---|
| 30 | | {
|
|---|
| 31 | | var panel = UI.panels.sources;
|
|---|
| 32 | | SourcesTestRunner.startDebuggerTest(step1, true);
|
|---|
| 33 | |
|
|---|
| 34 | | function callstackStatus()
|
|---|
| 35 | | {
|
|---|
| 36 | | var statusElement = panel.element.querySelector(".paused-message");
|
|---|
| 37 | | return statusElement ? statusElement.deepTextContent() : "not found";
|
|---|
| 24 | <script src="../../../inspector/inspector-test.js"></script>
|
|---|
| 25 | <script src="../../../inspector/debugger-test.js"></script>
|
|---|
| 26 |
|
|---|
| 27 | <script>
|
|---|
| 28 |
|
|---|
| 29 | var test = function() {
|
|---|
| 30 | var panel = UI.panels.sources;
|
|---|
| 31 | SourcesTestRunner.startDebuggerTest(step1, true);
|
|---|
| 32 |
|
|---|
| 33 | function callstackStatus() {
|
|---|
| 34 | var statusElement = panel.element.querySelector('.paused-message');
|
|---|
| 35 | return statusElement ? statusElement.deepTextContent() : 'not found';
|
|---|
| 36 | }
|
|---|
| 37 |
|
|---|
| 38 | function step1() {
|
|---|
| 39 | SourcesTestRunner.showScriptSource('debug-inlined-scripts.html', step2);
|
|---|
| 40 | }
|
|---|
| 41 |
|
|---|
| 42 | function step2(sourceFrame) {
|
|---|
| 43 | TestRunner.addResult('Script source was shown.');
|
|---|
| 44 |
|
|---|
| 45 | SourcesTestRunner.setBreakpoint(sourceFrame, 2, '', true);
|
|---|
| 46 | SourcesTestRunner.setBreakpoint(sourceFrame, 9, '', true);
|
|---|
| 47 |
|
|---|
| 48 | SourcesTestRunner.waitJavaScriptSourceFrameBreakpoints(sourceFrame).then(() => {
|
|---|
| 49 | TestRunner.reloadPage(() => SourcesTestRunner.completeDebuggerTest());
|
|---|
| 50 | });
|
|---|
| 51 |
|
|---|
| 52 | SourcesTestRunner.waitUntilPaused(step3);
|
|---|
| 53 | }
|
|---|
| 54 |
|
|---|
| 55 | function step3(callFrames) {
|
|---|
| 56 | TestRunner.addResult('Script execution paused.');
|
|---|
| 57 | SourcesTestRunner.captureStackTrace(callFrames);
|
|---|
| 58 | TestRunner.addResult('Call stack status: ' + callstackStatus());
|
|---|
| 59 | SourcesTestRunner.showScriptSource('debug-inlined-scripts.html', step4);
|
|---|
| 60 | }
|
|---|
| 61 |
|
|---|
| 62 | function step4(sourceFrame) {
|
|---|
| 63 | SourcesTestRunner.dumpSourceFrameContents(sourceFrame);
|
|---|
| 64 | SourcesTestRunner.resumeExecution(SourcesTestRunner.waitUntilPaused.bind(null, step5));
|
|---|
| 65 | }
|
|---|
| 66 |
|
|---|
| 67 | function step5(callFrames) {
|
|---|
| 68 | if (callFrames[0].location().lineNumber !== 9) {
|
|---|
| 69 | SourcesTestRunner.resumeExecution(SourcesTestRunner.waitUntilPaused.bind(null, step5));
|
|---|
| 70 | return;
|
|---|
| 38 | 71 | }
|
|---|
| 39 | 72 |
|
|---|
| 40 | | function step1()
|
|---|
| 41 | | {
|
|---|
| 42 | | SourcesTestRunner.showScriptSource("debug-inlined-scripts.html", step2);
|
|---|
| 43 | | }
|
|---|
| 44 | |
|
|---|
| 45 | | function step2(sourceFrame)
|
|---|
| 46 | | {
|
|---|
| 47 | | TestRunner.addResult("Script source was shown.");
|
|---|
| 48 | |
|
|---|
| 49 | | SourcesTestRunner.setBreakpoint(sourceFrame, 2, "", true);
|
|---|
| 50 | | SourcesTestRunner.setBreakpoint(sourceFrame, 9, "", true);
|
|---|
| 51 | |
|
|---|
| 52 | | SourcesTestRunner.waitJavaScriptSourceFrameBreakpoints(sourceFrame)
|
|---|
| 53 | | .then(() => {
|
|---|
| 54 | | TestRunner.reloadPage(() => SourcesTestRunner.completeDebuggerTest());
|
|---|
| 55 | | });
|
|---|
| 56 | |
|
|---|
| 57 | | SourcesTestRunner.waitUntilPaused(step3);
|
|---|
| 58 | | }
|
|---|
| 59 | |
|
|---|
| 60 | | function step3(callFrames)
|
|---|
| 61 | | {
|
|---|
| 62 | | TestRunner.addResult("Script execution paused.");
|
|---|
| 63 | | SourcesTestRunner.captureStackTrace(callFrames);
|
|---|
| 64 | | TestRunner.addResult("Call stack status: " + callstackStatus());
|
|---|
| 65 | | SourcesTestRunner.showScriptSource("debug-inlined-scripts.html", step4);
|
|---|
| 66 | | }
|
|---|
| 67 | |
|
|---|
| 68 | | function step4(sourceFrame)
|
|---|
| 69 | | {
|
|---|
| 70 | | SourcesTestRunner.dumpSourceFrameContents(sourceFrame);
|
|---|
| 71 | | SourcesTestRunner.resumeExecution(SourcesTestRunner.waitUntilPaused.bind(null, step5));
|
|---|
| 72 | | }
|
|---|
| 73 | |
|
|---|
| 74 | | function step5(callFrames)
|
|---|
| 75 | | {
|
|---|
| 76 | | if (callFrames[0].location().lineNumber !== 9) {
|
|---|
| 77 | | SourcesTestRunner.resumeExecution(SourcesTestRunner.waitUntilPaused.bind(null, step5));
|
|---|
| 78 | | return;
|
|---|
| 79 | | }
|
|---|
| 80 | |
|
|---|
| 81 | | TestRunner.addResult("Script execution paused.");
|
|---|
| 82 | | SourcesTestRunner.captureStackTrace(callFrames);
|
|---|
| 83 | | SourcesTestRunner.showScriptSource("debug-inlined-scripts.html", step6);
|
|---|
| 84 | | }
|
|---|
| 85 | |
|
|---|
| 86 | | function step6(sourceFrame)
|
|---|
| 87 | | {
|
|---|
| 88 | | SourcesTestRunner.dumpSourceFrameContents(sourceFrame);
|
|---|
| 89 | | SourcesTestRunner.resumeExecution(SourcesTestRunner.waitUntilPaused.bind(null, step7));
|
|---|
| 90 | | }
|
|---|
| 91 | |
|
|---|
| 92 | | function step7()
|
|---|
| 93 | | {
|
|---|
| 94 | | SourcesTestRunner.resumeExecution(SourcesTestRunner.waitUntilPaused.bind(null, step5));
|
|---|
| 95 | | }
|
|---|
| 96 | | }
|
|---|
| 73 | TestRunner.addResult('Script execution paused.');
|
|---|
| 74 | SourcesTestRunner.captureStackTrace(callFrames);
|
|---|
| 75 | SourcesTestRunner.showScriptSource('debug-inlined-scripts.html', step6);
|
|---|
| 76 | }
|
|---|
| 77 |
|
|---|
| 78 | function step6(sourceFrame) {
|
|---|
| 79 | SourcesTestRunner.dumpSourceFrameContents(sourceFrame);
|
|---|
| 80 | SourcesTestRunner.resumeExecution(SourcesTestRunner.waitUntilPaused.bind(null, step7));
|
|---|
| 81 | }
|
|---|
| 82 |
|
|---|
| 83 | function step7() {
|
|---|
| 84 | SourcesTestRunner.resumeExecution(SourcesTestRunner.waitUntilPaused.bind(null, step5));
|
|---|
| 85 | }
|
|---|
| 86 | };
|
|---|
| 97 | 87 |
|
|---|
| 98 | 88 | </script>
|
|---|
| 99 | 89 |
|
|---|
|
|
| 128 | 118 | f4();
|
|---|
| 129 | 119 | </script>
|
|---|
| 130 | 120 |
|
|---|
| 131 | | <script src="../../../http/tests/inspector/inspector-test.js"></script>
|
|---|
| 132 | | <script src="../../../http/tests/inspector/debugger-test.js"></script>
|
|---|
| 133 | |
|
|---|
| 134 | | <script>
|
|---|
| 135 | |
|
|---|
| 136 | | var test = function()
|
|---|
| 137 | | {
|
|---|
| 138 | | var panel = UI.panels.sources;
|
|---|
| 139 | | SourcesTestRunner.startDebuggerTest(step1, true);
|
|---|
| 140 | |
|
|---|
| 141 | | function callstackStatus()
|
|---|
| 142 | | {
|
|---|
| 143 | | var statusElement = panel.element.querySelector(".paused-message");
|
|---|
| 144 | | return statusElement ? statusElement.deepTextContent() : "not found";
|
|---|
| 121 | <script src="../../../inspector/inspector-test.js"></script>
|
|---|
| 122 | <script src="../../../inspector/debugger-test.js"></script>
|
|---|
| 123 |
|
|---|
| 124 | <script>
|
|---|
| 125 |
|
|---|
| 126 | var test = function() {
|
|---|
| 127 | var panel = UI.panels.sources;
|
|---|
| 128 | SourcesTestRunner.startDebuggerTest(step1, true);
|
|---|
| 129 |
|
|---|
| 130 | function callstackStatus() {
|
|---|
| 131 | var statusElement = panel.element.querySelector('.paused-message');
|
|---|
| 132 | return statusElement ? statusElement.deepTextContent() : 'not found';
|
|---|
| 133 | }
|
|---|
| 134 |
|
|---|
| 135 | function step1() {
|
|---|
| 136 | SourcesTestRunner.showScriptSource('debug-inlined-scripts.html', step2);
|
|---|
| 137 | }
|
|---|
| 138 |
|
|---|
| 139 | function step2(sourceFrame) {
|
|---|
| 140 | TestRunner.addResult('Script source was shown.');
|
|---|
| 141 |
|
|---|
| 142 | SourcesTestRunner.setBreakpoint(sourceFrame, 2, '', true);
|
|---|
| 143 | SourcesTestRunner.setBreakpoint(sourceFrame, 9, '', true);
|
|---|
| 144 |
|
|---|
| 145 | SourcesTestRunner.waitJavaScriptSourceFrameBreakpoints(sourceFrame).then(() => {
|
|---|
| 146 | TestRunner.reloadPage(() => SourcesTestRunner.completeDebuggerTest());
|
|---|
| 147 | });
|
|---|
| 148 |
|
|---|
| 149 | SourcesTestRunner.waitUntilPaused(step3);
|
|---|
| 150 | }
|
|---|
| 151 |
|
|---|
| 152 | function step3(callFrames) {
|
|---|
| 153 | TestRunner.addResult('Script execution paused.');
|
|---|
| 154 | SourcesTestRunner.captureStackTrace(callFrames);
|
|---|
| 155 | TestRunner.addResult('Call stack status: ' + callstackStatus());
|
|---|
| 156 | SourcesTestRunner.showScriptSource('debug-inlined-scripts.html', step4);
|
|---|
| 157 | }
|
|---|
| 158 |
|
|---|
| 159 | function step4(sourceFrame) {
|
|---|
| 160 | SourcesTestRunner.dumpSourceFrameContents(sourceFrame);
|
|---|
| 161 | SourcesTestRunner.resumeExecution(SourcesTestRunner.waitUntilPaused.bind(null, step5));
|
|---|
| 162 | }
|
|---|
| 163 |
|
|---|
| 164 | function step5(callFrames) {
|
|---|
| 165 | if (callFrames[0].location().lineNumber !== 9) {
|
|---|
| 166 | SourcesTestRunner.resumeExecution(SourcesTestRunner.waitUntilPaused.bind(null, step5));
|
|---|
| 167 | return;
|
|---|
| 145 | 168 | }
|
|---|
| 146 | 169 |
|
|---|
| 147 | | function step1()
|
|---|
| 148 | | {
|
|---|
| 149 | | SourcesTestRunner.showScriptSource("debug-inlined-scripts.html", step2);
|
|---|
| 150 | | }
|
|---|
| 151 | |
|
|---|
| 152 | | function step2(sourceFrame)
|
|---|
| 153 | | {
|
|---|
| 154 | | TestRunner.addResult("Script source was shown.");
|
|---|
| 155 | |
|
|---|
| 156 | | SourcesTestRunner.setBreakpoint(sourceFrame, 2, "", true);
|
|---|
| 157 | | SourcesTestRunner.setBreakpoint(sourceFrame, 9, "", true);
|
|---|
| 158 | |
|
|---|
| 159 | | SourcesTestRunner.waitJavaScriptSourceFrameBreakpoints(sourceFrame)
|
|---|
| 160 | | .then(() => {
|
|---|
| 161 | | TestRunner.reloadPage(() => SourcesTestRunner.completeDebuggerTest());
|
|---|
| 162 | | });
|
|---|
| 163 | |
|
|---|
| 164 | | SourcesTestRunner.waitUntilPaused(step3);
|
|---|
| 165 | | }
|
|---|
| 166 | |
|
|---|
| 167 | | function step3(callFrames)
|
|---|
| 168 | | {
|
|---|
| 169 | | TestRunner.addResult("Script execution paused.");
|
|---|
| 170 | | SourcesTestRunner.captureStackTrace(callFrames);
|
|---|
| 171 | | TestRunner.addResult("Call stack status: " + callstackStatus());
|
|---|
| 172 | | SourcesTestRunner.showScriptSource("debug-inlined-scripts.html", step4);
|
|---|
| 173 | | }
|
|---|
| 174 | |
|
|---|
| 175 | | function step4(sourceFrame)
|
|---|
| 176 | | {
|
|---|
| 177 | | SourcesTestRunner.dumpSourceFrameContents(sourceFrame);
|
|---|
| 178 | | SourcesTestRunner.resumeExecution(SourcesTestRunner.waitUntilPaused.bind(null, step5));
|
|---|
| 179 | | }
|
|---|
| 180 | |
|
|---|
| 181 | | function step5(callFrames)
|
|---|
| 182 | | {
|
|---|
| 183 | | if (callFrames[0].location().lineNumber !== 9) {
|
|---|
| 184 | | SourcesTestRunner.resumeExecution(SourcesTestRunner.waitUntilPaused.bind(null, step5));
|
|---|
| 185 | | return;
|
|---|
| 186 | | }
|
|---|
| 187 | |
|
|---|
| 188 | | TestRunner.addResult("Script execution paused.");
|
|---|
| 189 | | SourcesTestRunner.captureStackTrace(callFrames);
|
|---|
| 190 | | SourcesTestRunner.showScriptSource("debug-inlined-scripts.html", step6);
|
|---|
| 191 | | }
|
|---|
| 192 | |
|
|---|
| 193 | | function step6(sourceFrame)
|
|---|
| 194 | | {
|
|---|
| 195 | | SourcesTestRunner.dumpSourceFrameContents(sourceFrame);
|
|---|
| 196 | | SourcesTestRunner.resumeExecution(SourcesTestRunner.waitUntilPaused.bind(null, step7));
|
|---|
| 197 | | }
|
|---|
| 198 | |
|
|---|
| 199 | | function step7()
|
|---|
| 200 | | {
|
|---|
| 201 | | SourcesTestRunner.resumeExecution(SourcesTestRunner.waitUntilPaused.bind(null, step5));
|
|---|
| 202 | | }
|
|---|
| 203 | | }
|
|---|
| 170 | TestRunner.addResult('Script execution paused.');
|
|---|
| 171 | SourcesTestRunner.captureStackTrace(callFrames);
|
|---|
| 172 | SourcesTestRunner.showScriptSource('debug-inlined-scripts.html', step6);
|
|---|
| 173 | }
|
|---|
| 174 |
|
|---|
| 175 | function step6(sourceFrame) {
|
|---|
| 176 | SourcesTestRunner.dumpSourceFrameContents(sourceFrame);
|
|---|
| 177 | SourcesTestRunner.resumeExecution(SourcesTestRunner.waitUntilPaused.bind(null, step7));
|
|---|
| 178 | }
|
|---|
| 179 |
|
|---|
| 180 | function step7() {
|
|---|
| 181 | SourcesTestRunner.resumeExecution(SourcesTestRunner.waitUntilPaused.bind(null, step5));
|
|---|
| 182 | }
|
|---|
| 183 | };
|
|---|
| 204 | 184 |
|
|---|
| 205 | 185 | </script>
|
|---|
| 206 | 186 |
|
|---|
|
|