| Index: third_party/WebKit/LayoutTests/presentation/resources/presentation-service-mock.js
|
| diff --git a/third_party/WebKit/LayoutTests/presentation/resources/presentation-service-mock.js b/third_party/WebKit/LayoutTests/presentation/resources/presentation-service-mock.js
|
| index 15007fe7f8f7b0243d2dc677a155025db995b5e7..16a3fad53ac8151094d84993d1464214efbc852a 100644
|
| --- a/third_party/WebKit/LayoutTests/presentation/resources/presentation-service-mock.js
|
| +++ b/third_party/WebKit/LayoutTests/presentation/resources/presentation-service-mock.js
|
| @@ -25,10 +25,15 @@ let presentationServiceMock = loadMojoModules(
|
| this.pendingResponse_ = null;
|
| this.bindingSet_ = new bindings.BindingSet(
|
| presentationService.PresentationService);
|
| +
|
| + this.onSetClient = null;
|
| }
|
|
|
| setClient(client) {
|
| this.client_ = client;
|
| +
|
| + if (this.onSetClient)
|
| + this.onSetClient();
|
| }
|
|
|
| startSession(urls) {
|
| @@ -45,6 +50,19 @@ let presentationServiceMock = loadMojoModules(
|
| });
|
| }
|
|
|
| + terminate(presentationUrl, presentationId) {
|
| + this.client_.onConnectionStateChanged(
|
| + { url: presentationUrl, id: presentationId },
|
| + presentationService.PresentationConnectionState.TERMINATED);
|
| + }
|
| +
|
| + setPresentationConnection(
|
| + seesionInfo, controllerConnectionPtr, receiverConnectionRequest) {
|
| + this.client_.onConnectionStateChanged(
|
| + seesionInfo,
|
| + presentationService.PresentationConnectionState.CONNECTED);
|
| + }
|
| +
|
| onReceiverConnectionAvailable(strUrl, id) {
|
| const mojoUrl = new url.Url();
|
| mojoUrl.url = strUrl;
|
|
|