Remove obsolete entries from .gitignore.
[chromium-blink-merge.git] / media / video / mock_video_decode_accelerator.h
blobf8bb6da8756753f892f16e11ae04b6c2b3ef12a4
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 MEDIA_VIDEO_MOCK_VIDEO_DECODE_ACCELERATOR_H_
6 #define MEDIA_VIDEO_MOCK_VIDEO_DECODE_ACCELERATOR_H_
8 #include "video_decode_accelerator.h"
10 #include <vector>
12 #include "base/basictypes.h"
13 #include "media/base/bitstream_buffer.h"
14 #include "media/base/video_decoder_config.h"
15 #include "media/video/picture.h"
16 #include "testing/gmock/include/gmock/gmock.h"
18 namespace media {
20 // Remember to use the default action of Destroy() when using EXPECT_CALL.
21 // Otherwise, the mock will be leaked and the test runner will complain.
22 class MockVideoDecodeAccelerator : public VideoDecodeAccelerator {
23 public:
24 MockVideoDecodeAccelerator();
25 virtual ~MockVideoDecodeAccelerator();
27 MOCK_METHOD2(Initialize, bool(VideoCodecProfile profile, Client* client));
28 MOCK_METHOD1(Decode, void(const BitstreamBuffer& bitstream_buffer));
29 MOCK_METHOD1(AssignPictureBuffers,
30 void(const std::vector<PictureBuffer>& buffers));
31 MOCK_METHOD1(ReusePictureBuffer, void(int32 picture_buffer_id));
32 MOCK_METHOD0(Flush, void());
33 MOCK_METHOD0(Reset, void());
34 MOCK_METHOD0(Destroy, void());
35 MOCK_METHOD0(CanDecodeOnIOThread, bool());
37 private:
38 void DeleteThis();
39 DISALLOW_COPY_AND_ASSIGN(MockVideoDecodeAccelerator);
42 } // namespace media
44 #endif // MEDIA_VIDEO_MOCK_VIDEO_DECODE_ACCELERATOR_H_