mock_frame_decryptor.h (1249B)
1 /* 2 * Copyright 2018 The WebRTC project authors. All Rights Reserved. 3 * 4 * Use of this source code is governed by a BSD-style license 5 * that can be found in the LICENSE file in the root of the source 6 * tree. An additional intellectual property rights grant can be found 7 * in the file PATENTS. All contributing project authors may 8 * be found in the AUTHORS file in the root of the source tree. 9 */ 10 11 #ifndef API_TEST_MOCK_FRAME_DECRYPTOR_H_ 12 #define API_TEST_MOCK_FRAME_DECRYPTOR_H_ 13 14 #include <cstddef> 15 #include <cstdint> 16 #include <vector> 17 18 #include "api/array_view.h" 19 #include "api/crypto/frame_decryptor_interface.h" 20 #include "api/media_types.h" 21 #include "test/gmock.h" 22 23 namespace webrtc { 24 25 class MockFrameDecryptor : public FrameDecryptorInterface { 26 public: 27 MOCK_METHOD(Result, 28 Decrypt, 29 (MediaType, 30 const std::vector<uint32_t>&, 31 ArrayView<const uint8_t>, 32 ArrayView<const uint8_t>, 33 ArrayView<uint8_t>), 34 (override)); 35 36 MOCK_METHOD(size_t, 37 GetMaxPlaintextByteSize, 38 (MediaType, size_t encrypted_frame_size), 39 (override)); 40 }; 41 42 } // namespace webrtc 43 44 #endif // API_TEST_MOCK_FRAME_DECRYPTOR_H_