| Index: content/renderer/presentation/test_presentation_connection.h
|
| diff --git a/content/renderer/presentation/test_presentation_connection.h b/content/renderer/presentation/test_presentation_connection.h
|
| new file mode 100644
|
| index 0000000000000000000000000000000000000000..16ba3cdd1517b275754580fdfd80f59e80b03dab
|
| --- /dev/null
|
| +++ b/content/renderer/presentation/test_presentation_connection.h
|
| @@ -0,0 +1,34 @@
|
| +// Copyright 2017 The Chromium Authors. All rights reserved.
|
| +// Use of this source code is governed by a BSD-style license that can be
|
| +// found in the LICENSE file.
|
| +
|
| +#ifndef CONTENT_RENDERER_PRESENTATION_PRESENTATION_CONNECTION_TEST_HELPER_H_
|
| +#define CONTENT_RENDERER_PRESENTATION_PRESENTATION_CONNECTION_TEST_HELPER_H_
|
| +
|
| +#include <memory>
|
| +
|
| +#include "testing/gmock/include/gmock/gmock.h"
|
| +#include "third_party/WebKit/public/platform/modules/presentation/WebPresentationConnection.h"
|
| +
|
| +namespace content {
|
| +
|
| +class TestPresentationConnection : public blink::WebPresentationConnection {
|
| + public:
|
| + TestPresentationConnection();
|
| + ~TestPresentationConnection();
|
| +
|
| + void bindProxy(
|
| + std::unique_ptr<blink::WebPresentationConnectionProxy> proxy) override;
|
| +
|
| + MOCK_METHOD1(didReceiveTextMessage, void(const blink::WebString& message));
|
| + MOCK_METHOD2(didReceiveBinaryMessage,
|
| + void(const uint8_t* data, size_t length));
|
| + MOCK_METHOD1(didChangeState, void(blink::WebPresentationConnectionState));
|
| +
|
| + private:
|
| + std::unique_ptr<blink::WebPresentationConnectionProxy> proxy_;
|
| +};
|
| +
|
| +} // namespace content
|
| +
|
| +#endif // CONTENT_RENDERER_PRESENTATION_PRESENTATION_CONNECTION_TEST_HELPER_H_
|
|
|