| OLD | NEW |
| 1 <style>code{background-color: #ffc;}</style> | 1 <style>code{background-color: #ffc;}</style> |
| 2 <p><b>Test for <a href="https://bugs.webkit.org/show_bug.cgi?id=31375">Bug 31375
</a> - Web Inspector: breakpoints in named evals are not restored after a reload
</b> | 2 <p><b>Test for <a href="https://bugs.webkit.org/show_bug.cgi?id=31375">Bug 31375
</a> - Web Inspector: breakpoints in named evals are not restored after a reload
</b> |
| 3 | 3 |
| 4 <ul> | 4 <ul> |
| 5 <li><p>open this page with Web Inspector | 5 <li><p>open this page with Web Inspector |
| 6 <li><p>switch to the Scripts panel, enabling debug if required | 6 <li><p>switch to the Scripts panel, enabling debug if required |
| 7 <li><p>the available scripts in the select element should be: | 7 <li><p>the available scripts in the select element should be: |
| 8 <ul> | 8 <ul> |
| 9 <li>(program): f1.js | 9 <li>(program): f1.js |
| 10 <li>(program): f2.js | 10 <li>(program): f2.js |
| (...skipping 24 matching lines...) Expand all Loading... |
| 35 | 35 |
| 36 <script> | 36 <script> |
| 37 | 37 |
| 38 function doNothing() { /* allows multi-line functions, easier to debug */ }; | 38 function doNothing() { /* allows multi-line functions, easier to debug */ }; |
| 39 | 39 |
| 40 eval([ | 40 eval([ |
| 41 "function f1() {", | 41 "function f1() {", |
| 42 " doNothing();", | 42 " doNothing();", |
| 43 " console.log(new Date() + ': f1() called');", | 43 " console.log(new Date() + ': f1() called');", |
| 44 "}", | 44 "}", |
| 45 "//@sourceURL=f1.js" | 45 "//# sourceURL=f1.js" |
| 46 ].join("\n")); | 46 ].join("\n")); |
| 47 | 47 |
| 48 f2 = Function([ | 48 f2 = Function([ |
| 49 "", | 49 "", |
| 50 " doNothing();", | 50 " doNothing();", |
| 51 " console.log(new Date() + ': f2() called');", | 51 " console.log(new Date() + ': f2() called');", |
| 52 "//@sourceURL=f2.js" | 52 "//# sourceURL=f2.js" |
| 53 ].join("\n")); | 53 ].join("\n")); |
| 54 | 54 |
| 55 var button = document.getElementById("button"); | 55 var button = document.getElementById("button"); |
| 56 | 56 |
| 57 button.addEventListener("click", clickHandler, false); | 57 button.addEventListener("click", clickHandler, false); |
| 58 | 58 |
| 59 function clickHandler() { | 59 function clickHandler() { |
| 60 f1(); | 60 f1(); |
| 61 f2(); | 61 f2(); |
| 62 } | 62 } |
| 63 | 63 |
| 64 </script> | 64 </script> |
| 65 <!-- End --> | 65 <!-- End --> |
| OLD | NEW |