mock_frame_decryptor.h 1.2 KB

12345678910111213141516171819202122232425262728293031323334353637383940
  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. #ifndef API_TEST_MOCK_FRAME_DECRYPTOR_H_
  11. #define API_TEST_MOCK_FRAME_DECRYPTOR_H_
  12. #include <vector>
  13. #include "api/crypto/frame_decryptor_interface.h"
  14. #include "test/gmock.h"
  15. namespace webrtc {
  16. class MockFrameDecryptor : public FrameDecryptorInterface {
  17. public:
  18. MOCK_METHOD(Result,
  19. Decrypt,
  20. (cricket::MediaType,
  21. const std::vector<uint32_t>&,
  22. rtc::ArrayView<const uint8_t>,
  23. rtc::ArrayView<const uint8_t>,
  24. rtc::ArrayView<uint8_t>),
  25. (override));
  26. MOCK_METHOD(size_t,
  27. GetMaxPlaintextByteSize,
  28. (cricket::MediaType, size_t encrypted_frame_size),
  29. (override));
  30. };
  31. } // namespace webrtc
  32. #endif // API_TEST_MOCK_FRAME_DECRYPTOR_H_