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

Unified Diff: ppapi/native_client/tools/browser_tester/browserdata/nacltest.js

Issue 10918152: Port nacl_integration exit_status test to browser_tests. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 8 years, 3 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 side-by-side diff with in-line comments
Download patch
Index: ppapi/native_client/tools/browser_tester/browserdata/nacltest.js
diff --git a/ppapi/native_client/tools/browser_tester/browserdata/nacltest.js b/ppapi/native_client/tools/browser_tester/browserdata/nacltest.js
index 7dc9083b882e16640e47d354ee16d8faae3ef775..d71ebb7ee081725608cf05f4047b3b542509ed61 100644
--- a/ppapi/native_client/tools/browser_tester/browserdata/nacltest.js
+++ b/ppapi/native_client/tools/browser_tester/browserdata/nacltest.js
@@ -117,7 +117,15 @@ function RPCWrapper() {
// Performs a URL-encoded RPC call, given a function name and a dictionary
// (actually just an object - it's a JS idiom) of parameters.
function rpcCall(name, params) {
- if (this_.rpc_available) {
+ if (window.domAutomationController !== undefined) {
+ // Running as a Chrome browser_test.
+ var msg = {type: name};
+ for (var pname in params) {
+ msg[pname] = params[pname];
+ }
+ domAutomationController.setAutomationId(0);
+ domAutomationController.send(JSON.stringify(msg));
+ } else if (this_.rpc_available) {
// Construct the URL for the RPC request.
var args = [];
for (var pname in params) {

Powered by Google App Engine
This is Rietveld 408576698