OLD | NEW |
1 var initialize_InspectorTest = function() { | 1 var initialize_InspectorTest = function() { |
2 | 2 |
3 var results = []; | 3 var results = []; |
4 var resultsSynchronized = false; | 4 var resultsSynchronized = false; |
5 | 5 |
6 function consoleOutputHook(messageType) | 6 function consoleOutputHook(messageType) |
7 { | 7 { |
8 InspectorTest.addResult(messageType + ": " + Array.prototype.slice.call(argu
ments, 1)); | 8 InspectorTest.addResult(messageType + ": " + Array.prototype.slice.call(argu
ments, 1)); |
9 } | 9 } |
10 | 10 |
(...skipping 97 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
108 } | 108 } |
109 eval(functionName + "(" + evalCallback + ")"); | 109 eval(functionName + "(" + evalCallback + ")"); |
110 } | 110 } |
111 InspectorTest.evaluateInPage("(" + asyncEvalWrapper.toString() + ")(" + id +
", unescape('" + escape(functionName) + "'))"); | 111 InspectorTest.evaluateInPage("(" + asyncEvalWrapper.toString() + ")(" + id +
", unescape('" + escape(functionName) + "'))"); |
112 } | 112 } |
113 | 113 |
114 InspectorTest.didInvokePageFunctionAsync = function(callId, value) | 114 InspectorTest.didInvokePageFunctionAsync = function(callId, value) |
115 { | 115 { |
116 var callback = pendingEvalRequests[callId]; | 116 var callback = pendingEvalRequests[callId]; |
117 if (!callback) { | 117 if (!callback) { |
118 InspectorTest.addResult("Missing callback for ascyn eval " + callId + ",
perhaps callback invoked twice?"); | 118 InspectorTest.addResult("Missing callback for async eval " + callId + ",
perhaps callback invoked twice?"); |
119 return; | 119 return; |
120 } | 120 } |
121 delete pendingEvalRequests[callId]; | 121 delete pendingEvalRequests[callId]; |
122 callback(value); | 122 callback(value); |
123 } | 123 } |
124 | 124 |
125 InspectorTest.check = function(passCondition, failureText) | 125 InspectorTest.check = function(passCondition, failureText) |
126 { | 126 { |
127 if (!passCondition) | 127 if (!passCondition) |
128 InspectorTest.addResult("FAIL: " + failureText); | 128 InspectorTest.addResult("FAIL: " + failureText); |
(...skipping 709 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
838 evaluateInWebInspector: function(callId, script) | 838 evaluateInWebInspector: function(callId, script) |
839 { | 839 { |
840 window.opener.postMessage(["evaluateInWebInspector", callId, script], "*
"); | 840 window.opener.postMessage(["evaluateInWebInspector", callId, script], "*
"); |
841 }, | 841 }, |
842 | 842 |
843 display: function() { } | 843 display: function() { } |
844 } | 844 } |
845 | 845 |
846 if (!window.testRunner && window.opener) | 846 if (!window.testRunner && window.opener) |
847 window.testRunner = new StandaloneTestRunnerStub(); | 847 window.testRunner = new StandaloneTestRunnerStub(); |
OLD | NEW |