blob: 40562685020805a3e4c6d285f57bbcba8df96651 [file] [log] [blame]
abhishek.a21bdd07a82014-09-25 06:34:101// Copyright 2013 The Chromium Authors. All rights reserved.
2// Use of this source code is governed by a BSD-style license that can be
3// found in the LICENSE file.
4
jochen73e711c2015-06-03 10:01:465#ifndef COMPONENTS_TEST_RUNNER_WEB_TEST_INTERFACES_H_
6#define COMPONENTS_TEST_RUNNER_WEB_TEST_INTERFACES_H_
abhishek.a21bdd07a82014-09-25 06:34:107
8#include "base/memory/scoped_ptr.h"
jochen746754c52015-06-05 16:40:419#include "components/test_runner/test_runner_export.h"
abhishek.a21bdd07a82014-09-25 06:34:1010
11namespace blink {
benwells0c0d3f12015-05-25 01:03:1712class WebAppBannerClient;
abhishek.a21bdd07a82014-09-25 06:34:1013class WebAudioDevice;
14class WebFrame;
15class WebMediaStreamCenter;
16class WebMediaStreamCenterClient;
17class WebMIDIAccessor;
18class WebMIDIAccessorClient;
19class WebRTCPeerConnectionHandler;
20class WebRTCPeerConnectionHandlerClient;
21class WebThemeEngine;
22class WebURL;
23class WebView;
24}
25
jochenf5f31752015-06-03 12:06:3426namespace test_runner {
abhishek.a21bdd07a82014-09-25 06:34:1027
jochen746754c52015-06-05 16:40:4128class AppBannerClient;
abhishek.a21bdd07a82014-09-25 06:34:1029class TestInterfaces;
30class WebTestDelegate;
31class WebTestProxyBase;
32class WebTestRunner;
33
jochen746754c52015-06-05 16:40:4134class TEST_RUNNER_EXPORT WebTestInterfaces {
abhishek.a21bdd07a82014-09-25 06:34:1035 public:
36 WebTestInterfaces();
37 ~WebTestInterfaces();
38
39 void SetWebView(blink::WebView* web_view, WebTestProxyBase* proxy);
40 void SetDelegate(WebTestDelegate* delegate);
41 void BindTo(blink::WebFrame* frame);
42 void ResetAll();
43 void SetTestIsRunning(bool running);
44 void ConfigureForTestWithURL(const blink::WebURL& test_url,
45 bool generate_pixels);
46
47 WebTestRunner* TestRunner();
48 blink::WebThemeEngine* ThemeEngine();
49
50 blink::WebMediaStreamCenter* CreateMediaStreamCenter(
51 blink::WebMediaStreamCenterClient* client);
52 blink::WebRTCPeerConnectionHandler* CreateWebRTCPeerConnectionHandler(
53 blink::WebRTCPeerConnectionHandlerClient* client);
54
55 blink::WebMIDIAccessor* CreateMIDIAccessor(
56 blink::WebMIDIAccessorClient* client);
57
58 blink::WebAudioDevice* CreateAudioDevice(double sample_rate);
59
benwells0c0d3f12015-05-25 01:03:1760 scoped_ptr<blink::WebAppBannerClient> CreateAppBannerClient();
jochen746754c52015-06-05 16:40:4161 AppBannerClient* GetAppBannerClient();
benwells0c0d3f12015-05-25 01:03:1762
abhishek.a21bdd07a82014-09-25 06:34:1063 TestInterfaces* GetTestInterfaces();
64
65 private:
66 scoped_ptr<TestInterfaces> interfaces_;
67
68 DISALLOW_COPY_AND_ASSIGN(WebTestInterfaces);
69};
70
jochenf5f31752015-06-03 12:06:3471} // namespace test_runner
abhishek.a21bdd07a82014-09-25 06:34:1072
jochen73e711c2015-06-03 10:01:4673#endif // COMPONENTS_TEST_RUNNER_WEB_TEST_INTERFACES_H_