[safe-browsing] Database full hash matches like prefix match.
[chromium-blink-merge.git] / content / shell / renderer / test_runner / MockWebMIDIAccessor.h
blob6298d35f02a9b43d1708b407c5c61c3583ae5bb6
1 // 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.
5 #ifndef CONTENT_SHELL_RENDERER_TEST_RUNNER_MOCKWEBMIDIACCESSOR_H_
6 #define CONTENT_SHELL_RENDERER_TEST_RUNNER_MOCKWEBMIDIACCESSOR_H_
8 #include "base/basictypes.h"
9 #include "content/shell/renderer/test_runner/TestCommon.h"
10 #include "content/shell/renderer/test_runner/WebTask.h"
11 #include "third_party/WebKit/public/platform/WebMIDIAccessor.h"
13 namespace blink {
14 class WebMIDIAccessorClient;
17 namespace WebTestRunner {
19 class TestInterfaces;
21 class MockWebMIDIAccessor : public blink::WebMIDIAccessor {
22 public:
23 explicit MockWebMIDIAccessor(blink::WebMIDIAccessorClient*, TestInterfaces*);
24 virtual ~MockWebMIDIAccessor();
26 // blink::WebMIDIAccessor implementation.
27 virtual void startSession() OVERRIDE;
28 virtual void sendMIDIData(
29 unsigned portIndex,
30 const unsigned char* data,
31 size_t length,
32 double timestamp) OVERRIDE { }
34 // WebTask related methods
35 WebTaskList* taskList() { return &m_taskList; }
37 private:
38 blink::WebMIDIAccessorClient* m_client;
39 WebTaskList m_taskList;
40 TestInterfaces* m_interfaces;
42 DISALLOW_COPY_AND_ASSIGN(MockWebMIDIAccessor);
45 } // namespace WebTestRunner
47 #endif // CONTENT_SHELL_RENDERER_TEST_RUNNER_MOCKWEBMIDIACCESSOR_H_