| Index: mojo/public/js/bindings/connector.js
|
| diff --git a/mojo/public/js/bindings/connector.js b/mojo/public/js/bindings/connector.js
|
| index cf7c93b8773e0345bdf36d3646d31a8443f7a2df..495896d3b2a59200c28b86c3c4163a891035f523 100644
|
| --- a/mojo/public/js/bindings/connector.js
|
| +++ b/mojo/public/js/bindings/connector.js
|
| @@ -104,7 +104,24 @@ define("mojo/public/js/bindings/connector", [
|
| }
|
| };
|
|
|
| + // The TestConnector subclass is only intended to be used in unit tests. It
|
| + // enables delivering a message to the pipe's handle without an async wait.
|
| +
|
| + function TestConnector(handle) {
|
| + Connector.call(this, handle);
|
| + }
|
| +
|
| + TestConnector.prototype = Object.create(Connector.prototype);
|
| +
|
| + TestConnector.prototype.waitToReadMore_ = function() {
|
| + };
|
| +
|
| + TestConnector.prototype.deliverMessage = function() {
|
| + this.readMore_(core.RESULT_OK);
|
| + }
|
| +
|
| var exports = {};
|
| exports.Connector = Connector;
|
| + exports.TestConnector = TestConnector;
|
| return exports;
|
| });
|
|
|