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

Side by Side Diff: LayoutTests/inspector-enabled/sources/debugger/linkifier.html

Issue 396993003: DevTools: get rid of WebInspector.cssModel, use target models instead (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 6 years, 5 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/debugger-test.js"></script> 4 <script src="../../../http/tests/inspector/debugger-test.js"></script>
5 <script> 5 <script>
6 6
7 function nonFormattedFunction() { var i = 2 + 2; var a = 4; return a + i; } 7 function nonFormattedFunction() { var i = 2 + 2; var a = 4; return a + i; }
8 8
9 function dummyScript() 9 function dummyScript()
10 { 10 {
(...skipping 38 matching lines...) Expand 10 before | Expand all | Expand 10 after
49 uiSourceCode = WebInspector.workspace.uiSourceCodeForOriginURL(WebInspec tor.resourceTreeModel.inspectedPageURL()); 49 uiSourceCode = WebInspector.workspace.uiSourceCodeForOriginURL(WebInspec tor.resourceTreeModel.inspectedPageURL());
50 var linkifyMe = "at triggerError (http://localhost/show/:22:11)"; 50 var linkifyMe = "at triggerError (http://localhost/show/:22:11)";
51 var fragment = WebInspector.linkifyStringAsFragment(linkifyMe); 51 var fragment = WebInspector.linkifyStringAsFragment(linkifyMe);
52 var anchor = fragment.querySelector('a'); 52 var anchor = fragment.querySelector('a');
53 InspectorTest.addResult("The string \"" + linkifyMe + " \" linkifies to url: " + anchor.href); 53 InspectorTest.addResult("The string \"" + linkifyMe + " \" linkifies to url: " + anchor.href);
54 InspectorTest.addResult("The lineNumber is " + anchor.lineNumber + " wit h type " + (typeof anchor.lineNumber)); 54 InspectorTest.addResult("The lineNumber is " + anchor.lineNumber + " wit h type " + (typeof anchor.lineNumber));
55 InspectorTest.addResult("The columnNumber is " + anchor.columnNumber + " with type " + (typeof anchor.columnNumber)); 55 InspectorTest.addResult("The columnNumber is " + anchor.columnNumber + " with type " + (typeof anchor.columnNumber));
56 56
57 linkifier = new WebInspector.Linkifier(); 57 linkifier = new WebInspector.Linkifier();
58 var count1 = liveLocationsCount(); 58 var count1 = liveLocationsCount();
59 link = linkifier.linkifyLocation(WebInspector.targetManager.activeTarget (), WebInspector.resourceTreeModel.inspectedPageURL(), 8, 0, "dummy-class"); 59 link = linkifier.linkifyLocation(WebInspector.targetManager.mainTarget() , WebInspector.resourceTreeModel.inspectedPageURL(), 8, 0, "dummy-class");
60 var count2 = liveLocationsCount(); 60 var count2 = liveLocationsCount();
61 61
62 InspectorTest.addResult("listeners added on raw source code: " + (count2 - count1)); 62 InspectorTest.addResult("listeners added on raw source code: " + (count2 - count1));
63 InspectorTest.addResult("original location: " + link.textContent); 63 InspectorTest.addResult("original location: " + link.textContent);
64 InspectorTest.addSniffer(WebInspector.ScriptFormatterEditorAction.protot ype, "_updateButton", uiSourceCodeScriptFormatted); 64 InspectorTest.addSniffer(WebInspector.ScriptFormatterEditorAction.protot ype, "_updateButton", uiSourceCodeScriptFormatted);
65 scriptFormatter._toggleFormatScriptSource(); 65 scriptFormatter._toggleFormatScriptSource();
66 } 66 }
67 67
68 function uiSourceCodeScriptFormatted() 68 function uiSourceCodeScriptFormatted()
69 { 69 {
(...skipping 19 matching lines...) Expand all
89 </script> 89 </script>
90 </head> 90 </head>
91 91
92 <body onload="onload()"> 92 <body onload="onload()">
93 <p> 93 <p>
94 Tests that Linkifier works correctly. 94 Tests that Linkifier works correctly.
95 <p> 95 <p>
96 96
97 </body> 97 </body>
98 </html> 98 </html>
OLDNEW
« no previous file with comments | « LayoutTests/http/tests/inspector/stylesheet-source-mapping.html ('k') | LayoutTests/inspector/console/command-line-api.html » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698