Index: mojo/edk/js/tests/js_to_cpp_tests.js |
diff --git a/mojo/edk/js/tests/js_to_cpp_tests.js b/mojo/edk/js/tests/js_to_cpp_tests.js |
index ddecc4b14b4c513f3a0feb815891b6291a8f9c3f..6b69fcacc8bea86b8d5be6e22dba055d5e6ee2fc 100644 |
--- a/mojo/edk/js/tests/js_to_cpp_tests.js |
+++ b/mojo/edk/js/tests/js_to_cpp_tests.js |
@@ -6,10 +6,9 @@ define('mojo/edk/js/tests/js_to_cpp_tests', [ |
'console', |
'mojo/edk/js/tests/js_to_cpp.mojom', |
'mojo/public/js/bindings', |
- 'mojo/public/js/connection', |
'mojo/public/js/connector', |
'mojo/public/js/core', |
-], function (console, jsToCpp, bindings, connection, connector, core) { |
+], function (console, jsToCpp, bindings, connector, core) { |
var retainedJsSide; |
var retainedJsSideStub; |
var sampleData; |
@@ -22,11 +21,9 @@ define('mojo/edk/js/tests/js_to_cpp_tests', [ |
}; |
function JsSideConnection() { |
+ this.binding = new bindings.Binding(jsToCpp.JsSide, this); |
} |
- JsSideConnection.prototype = |
- Object.create(jsToCpp.JsSide.stubClass.prototype); |
- |
JsSideConnection.prototype.setCppSide = function(cppSide) { |
this.cppSide_ = cppSide; |
this.cppSide_.startTest(); |
@@ -220,9 +217,7 @@ define('mojo/edk/js/tests/js_to_cpp_tests', [ |
for (i = 0; i < sampleMessage.length; ++i) { |
sampleMessage[i] = 255 - i; |
} |
- retainedJsSideStub = |
- connection.bindHandleToStub(jsSideRequestHandle, jsToCpp.JsSide); |
retainedJsSide = new JsSideConnection; |
- bindings.StubBindings(retainedJsSideStub).delegate = retainedJsSide; |
+ retainedJsSide.binding.bind(jsSideRequestHandle); |
}; |
}); |