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

Side by Side Diff: third_party/WebKit/LayoutTests/inspector-protocol/debugger/setScriptSource.html

Issue 2249743006: [DevTools] Fill ExceptionDetails with more details, unify usage across protocol. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: browser test Created 4 years, 4 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
OLDNEW
1 <html> 1 <html>
2 <head> 2 <head>
3 <script type="text/javascript" src="../../http/tests/inspector-protocol/inspecto r-protocol-test.js"></script> 3 <script type="text/javascript" src="../../http/tests/inspector-protocol/inspecto r-protocol-test.js"></script>
4 <script type="text/javascript" src="resources/liveedit-me.js"></script> 4 <script type="text/javascript" src="resources/liveedit-me.js"></script>
5 <script> 5 <script>
6 6
7 function test() 7 function test()
8 { 8 {
9 // A general-purpose engine for sending a sequence of protocol commands. 9 // A general-purpose engine for sending a sequence of protocol commands.
10 // The clients provide requests and response handlers, while the engine catc hes 10 // The clients provide requests and response handlers, while the engine catc hes
(...skipping 122 matching lines...) Expand 10 before | Expand all | Expand 10 after
133 function callbackEvalFunction2(result) { 133 function callbackEvalFunction2(result) {
134 InspectorTest.log("Function evaluate: " + JSON.stringify(result.resu lt)); 134 InspectorTest.log("Function evaluate: " + JSON.stringify(result.resu lt));
135 logEqualsCheck(result.result.value, 8); 135 logEqualsCheck(result.result.value, 8);
136 136
137 var patched = originalText.replace("a + b", "a # b"); 137 var patched = originalText.replace("a + b", "a # b");
138 138
139 return { command: "Debugger.setScriptSource", params: { scriptId: sc riptId, scriptSource: patched }, callback: errorCallbackSetScriptSource2 }; 139 return { command: "Debugger.setScriptSource", params: { scriptId: sc riptId, scriptSource: patched }, callback: errorCallbackSetScriptSource2 };
140 } 140 }
141 141
142 function errorCallbackSetScriptSource2(result) { 142 function errorCallbackSetScriptSource2(result) {
143 var compileError = result.compileError; 143 var exceptionDetails = result.exceptionDetails;
144 logCheck("Has error reported", !!compileError); 144 logCheck("Has error reported", !!exceptionDetails);
145 logCheck("Reported error is a compile error", !!compileError); 145 logCheck("Reported error is a compile error", !!exceptionDetails);
146 if (compileError) 146 if (exceptionDetails)
147 logEqualsCheck(compileError.lineNumber, 1); 147 logEqualsCheck(exceptionDetails.lineNumber, 1);
148 return next; 148 return next;
149 } 149 }
150 } 150 }
151 } 151 }
152 </script> 152 </script>
153 </head> 153 </head>
154 <body onLoad="runTest();"> 154 <body onLoad="runTest();">
155 </body> 155 </body>
156 </html> 156 </html>
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698