OLD | NEW |
| (Empty) |
1 // Copyright (c) 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 | |
5 #ifndef GPU_COMMAND_BUFFER_CLIENT_GPU_MEMORY_BUFFER_MOCK_H_ | |
6 #define GPU_COMMAND_BUFFER_CLIENT_GPU_MEMORY_BUFFER_MOCK_H_ | |
7 | |
8 #include "gpu/command_buffer/client/gpu_memory_buffer.h" | |
9 #include "base/basictypes.h" | |
10 #include "testing/gmock/include/gmock/gmock.h" | |
11 | |
12 namespace gpu { | |
13 | |
14 class GpuMemoryBufferMock : public GpuMemoryBuffer { | |
15 public: | |
16 GpuMemoryBufferMock(int width, int height); | |
17 virtual ~GpuMemoryBufferMock(); | |
18 | |
19 MOCK_METHOD2(Map, void(GpuMemoryBuffer::AccessMode, void**)); | |
20 MOCK_METHOD0(Unmap, void()); | |
21 MOCK_METHOD0(IsMapped, bool()); | |
22 MOCK_METHOD0(GetNativeBuffer, void*()); | |
23 MOCK_METHOD0(GetStride, uint32()); | |
24 MOCK_METHOD0(Die, void()); | |
25 | |
26 private: | |
27 DISALLOW_COPY_AND_ASSIGN(GpuMemoryBufferMock); | |
28 }; | |
29 | |
30 } // namespace gpu | |
31 | |
32 #endif // GPU_COMMAND_BUFFER_CLIENT_GPU_MEMORY_BUFFER_MOCK_H_ | |
OLD | NEW |