| OLD | NEW |
| 1 if (window.GCController) | 1 if (window.GCController) |
| 2 GCController.collectAll(); | 2 GCController.collectAll(); |
| 3 var initialize_InspectorTest = function() { | 3 var initialize_InspectorTest = function() { |
| 4 | 4 |
| 5 var results = []; | 5 var results = []; |
| 6 | 6 |
| 7 function consoleOutputHook(messageType) | 7 function consoleOutputHook(messageType) |
| 8 { | 8 { |
| 9 InspectorTest.addResult(messageType + ": " + Array.prototype.slice.call(argu
ments, 1)); | 9 InspectorTest.addResult(messageType + ": " + Array.prototype.slice.call(argu
ments, 1)); |
| 10 } | 10 } |
| (...skipping 56 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 67 var expression = "testRunner.evaluateInWebInspectorOverlay(\"(\" + " + func
+ " + \")()\")"; | 67 var expression = "testRunner.evaluateInWebInspectorOverlay(\"(\" + " + func
+ " + \")()\")"; |
| 68 var mainContext = InspectorTest.runtimeModel.executionContexts()[0]; | 68 var mainContext = InspectorTest.runtimeModel.executionContexts()[0]; |
| 69 mainContext.evaluate(expression, "", false, false, true, false, false, wrapC
allback); | 69 mainContext.evaluate(expression, "", false, false, true, false, false, wrapC
allback); |
| 70 | 70 |
| 71 function wrapCallback(val, err, result) | 71 function wrapCallback(val, err, result) |
| 72 { | 72 { |
| 73 callback(result.value) | 73 callback(result.value) |
| 74 } | 74 } |
| 75 } | 75 } |
| 76 | 76 |
| 77 InspectorTest.waitForOverlayRepaint = function(callback) |
| 78 { |
| 79 InspectorTest.invokePageFunctionAsync("requestAnimationFrame", callback); |
| 80 } |
| 81 |
| 77 var lastEvalId = 0; | 82 var lastEvalId = 0; |
| 78 var pendingEvalRequests = {}; | 83 var pendingEvalRequests = {}; |
| 79 | 84 |
| 80 var lastPromiseEvalId = 0; | 85 var lastPromiseEvalId = 0; |
| 81 var pendingPromiseEvalRequests = {}; | 86 var pendingPromiseEvalRequests = {}; |
| 82 | 87 |
| 83 /** | 88 /** |
| 84 * The given function should take two callback paraters before the arguments: | 89 * The given function should take two callback paraters before the arguments: |
| 85 * * resolve - called when successful (with optional result) | 90 * * resolve - called when successful (with optional result) |
| 86 * * reject - called when there was a failure (with optional error) | 91 * * reject - called when there was a failure (with optional error) |
| (...skipping 1126 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1213 _output("[page] " + text); | 1218 _output("[page] " + text); |
| 1214 } | 1219 } |
| 1215 | 1220 |
| 1216 function _output(result) | 1221 function _output(result) |
| 1217 { | 1222 { |
| 1218 if (!outputElement) | 1223 if (!outputElement) |
| 1219 createOutputElement(); | 1224 createOutputElement(); |
| 1220 outputElement.appendChild(document.createTextNode(result)); | 1225 outputElement.appendChild(document.createTextNode(result)); |
| 1221 outputElement.appendChild(document.createElement("br")); | 1226 outputElement.appendChild(document.createElement("br")); |
| 1222 } | 1227 } |
| OLD | NEW |