Updating trunk VERSION from 2139.0 to 2140.0
[chromium-blink-merge.git] / device / bluetooth / test / mock_bluetooth_socket.h
blob2d74cd71a6065473005f2d3ccf1d8167dc53e658
1 // Copyright (c) 2012 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 DEVICE_BLUETOOTH_TEST_MOCK_BLUETOOTH_SOCKET_H_
6 #define DEVICE_BLUETOOTH_TEST_MOCK_BLUETOOTH_SOCKET_H_
8 #include <string>
10 #include "device/bluetooth/bluetooth_socket.h"
11 #include "device/bluetooth/bluetooth_uuid.h"
12 #include "net/base/io_buffer.h"
13 #include "testing/gmock/include/gmock/gmock.h"
15 namespace device {
17 class MockBluetoothSocket : public BluetoothSocket {
18 public:
19 MockBluetoothSocket();
20 MOCK_METHOD0(Close, void());
21 MOCK_METHOD1(Disconnect, void(const base::Closure& success_callback));
22 MOCK_METHOD3(Receive,
23 void(int count,
24 const ReceiveCompletionCallback& success_callback,
25 const ReceiveErrorCompletionCallback& error_callback));
26 MOCK_METHOD4(Send,
27 void(scoped_refptr<net::IOBuffer> buffer,
28 int buffer_size,
29 const SendCompletionCallback& success_callback,
30 const ErrorCompletionCallback& error_callback));
31 MOCK_METHOD2(Accept,
32 void(const AcceptCompletionCallback& success_callback,
33 const ErrorCompletionCallback& error_callback));
35 protected:
36 virtual ~MockBluetoothSocket();
39 } // namespace device
41 #endif // DEVICE_BLUETOOTH_TEST_MOCK_BLUETOOTH_SOCKET_H_