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

Side by Side Diff: LayoutTests/inspector/console/console-trace-in-eval.html

Issue 15832007: DevTools: Add support for //# sourceURL (sourceMappingURL) comments and deprecate //@ ones (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Rebaselined Created 7 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
OLDNEW
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/console-test.js"></script> 4 <script src="../../http/tests/inspector/console-test.js"></script>
5 <script> 5 <script>
6 6
7 7
8 function evalSource() 8 function evalSource()
9 { 9 {
10 function b() 10 function b()
11 { 11 {
12 console.trace(); 12 console.trace();
13 } 13 }
14 14
15 function a() 15 function a()
16 { 16 {
17 b(); 17 b();
18 } 18 }
19 19
20 a(); 20 a();
21 } 21 }
22 22
23 function doEvalSource() 23 function doEvalSource()
24 { 24 {
25 setTimeout(function() { 25 setTimeout(function() {
26 eval("(" + evalSource + ")()//@ sourceURL=evalURL.js"); 26 eval("(" + evalSource + ")()//# sourceURL=evalURL.js");
27 }, 0); 27 }, 0);
28 } 28 }
29 29
30 function test() 30 function test()
31 { 31 {
32 function callback() 32 function callback()
33 { 33 {
34 InspectorTest.dumpConsoleMessages(); 34 InspectorTest.dumpConsoleMessages();
35 InspectorTest.completeTest(); 35 InspectorTest.completeTest();
36 } 36 }
37 InspectorTest.evaluateInPage("doEvalSource()"); 37 InspectorTest.evaluateInPage("doEvalSource()");
38 InspectorTest.addConsoleSniffer(callback); 38 InspectorTest.addConsoleSniffer(callback);
39 } 39 }
40 40
41 </script> 41 </script>
42 </head> 42 </head>
43 43
44 <body onload="runTest()"> 44 <body onload="runTest()">
45 <p> 45 <p>
46 Tests that when console.trace is called in eval'ed script ending 46 Tests that when console.trace is called in eval'ed script ending
47 with //@ sourceURL=url it will dump a stack trace that will have 47 with //# sourceURL=url it will dump a stack trace that will have
48 the url as the script source. <a href="https://bugs.webkit.org/show_bug.cgi?id=4 7252">Bug 47252.</a> 48 the url as the script source. <a href="https://bugs.webkit.org/show_bug.cgi?id=4 7252">Bug 47252.</a>
49 </p> 49 </p>
50 50
51 </body> 51 </body>
52 </html> 52 </html>
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698